Skip to content

Commit

Permalink
Lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ulisesmac committed Mar 8, 2024
1 parent 68d63e7 commit c7529bb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
(ns status-im.contexts.wallet.accounts.add-account.address-to-watch.events
(:require [clojure.string :as string]
[status-im.constants :as constants]
[utils.re-frame :as rf]
[taoensso.timbre :as log]))
[taoensso.timbre :as log]
[utils.re-frame :as rf]))

(rf/reg-event-fx
:wallet/ens-not-found
Expand Down
11 changes: 6 additions & 5 deletions src/status_im/contexts/wallet/add_address_to_watch/view.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@
[utils.re-frame :as rf]))

(defn- validate-address
[known-addresses s]
[known-addresses user-input]
(cond
(or (nil? s) (= s "")) nil
(contains? known-addresses s) (i18n/label :t/address-already-in-use)
(not (or (validation/eth-address? s)
(validation/ens-name? s))) (i18n/label :t/invalid-address)))
(or (nil? user-input) (= user-input "")) nil
(contains? known-addresses user-input) (i18n/label :t/address-already-in-use)
(not
(or (validation/eth-address? user-input)
(validation/ens-name? user-input))) (i18n/label :t/invalid-address)))

(defn- address-input
[{:keys [input-value validation-msg validate clear-input]}]
Expand Down

0 comments on commit c7529bb

Please sign in to comment.