[#11446] Can't sell item on opensea

Signed-off-by: andrey <motor4ik@gmail.com>
This commit is contained in:
andrey 2020-11-18 13:53:14 +01:00
parent e02f1bc89f
commit cb779e1599
No known key found for this signature in database
GPG Key ID: 89B67245FD2F0272
2 changed files with 3 additions and 3 deletions

View File

@ -317,7 +317,7 @@
(defn normalize-message
"NOTE (andrey) there is no spec for this, so this implementation just to be compatible with MM"
[message]
(if (ethereum/hex-to-utf8 message)
(if (string/starts-with? message "0x")
message
(ethereum/utf8-to-hex message)))
@ -330,7 +330,7 @@
(ethereum/address? first-param)
[first-param (if typed? second-param (normalize-message second-param))]
(ethereum/address? second-param)
[second-param (if typed? second-param (normalize-message first-param))]))))
[second-param (if typed? first-param (normalize-message first-param))]))))
(fx/defn send-to-bridge
[cofx message]

View File

@ -140,4 +140,4 @@
(defn hex->text
"Converts a hexstring to UTF8 text."
[data]
(hex-to-utf8 data))
(or (hex-to-utf8 data) data))