fix no icon for ETH in 1-1 transaction messages (#13898)
This commit is contained in:
parent
04b69181f2
commit
698e548c6d
|
@ -24,19 +24,10 @@
|
|||
|
||||
(defn network->icon [network]
|
||||
(let [s (str "./resources/images/tokens/" (name network) "/0-native.png")
|
||||
s-js (str "." s)
|
||||
image (gensym)]
|
||||
s-js (str "." s)]
|
||||
(if (.exists (io/file s))
|
||||
`(let [~image (atom nil)]
|
||||
(fn []
|
||||
(or @~image
|
||||
(reset! ~image (js/require ~s-js)))))
|
||||
`(let [~image (atom nil)]
|
||||
(fn []
|
||||
(or
|
||||
@~image
|
||||
(reset! ~image
|
||||
(js/require "../resources/images/tokens/default-token.png"))))))))
|
||||
`(js/require ~s-js)
|
||||
`(js/require "../resources/images/tokens/default-token.png"))))
|
||||
|
||||
(defmacro resolve-native-currency-icons
|
||||
"In react-native arguments to require must be static strings.
|
||||
|
|
Loading…
Reference in New Issue