Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#12460] Allow assets name collision #12466

Merged
merged 1 commit into from
Aug 23, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
[#12460] Allow assets name collision
  • Loading branch information
rasom committed Aug 23, 2021
commit 37d893d5f863991ad37b393fe7f9ac54e444a3d8
11 changes: 3 additions & 8 deletions src/status_im/wallet/custom_tokens/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -145,14 +145,9 @@
(fx/defn name-result
{:events [:wallet.custom-token/name-result]}
[{:keys [db]} contract token-name]
(let [name-exists? (field-exists? db :name token-name)]
{:db
(update db :wallet/custom-token-screen merge
{:name token-name
:error-name (when name-exists?
(i18n/label :t/you-already-have-an-asset
{:value token-name}))})
:wallet.custom-token/get-symbol contract}))
{:db
(update db :wallet/custom-token-screen merge {:name token-name})
:wallet.custom-token/get-symbol contract})

(fx/defn balance-result
{:events [:wallet.custom-token/balance-result]}
Expand Down