From 52c8fc967d11eca78a2f31443887de135202eb93 Mon Sep 17 00:00:00 2001 From: angusiguess Date: Tue, 22 Aug 2017 14:17:59 -0300 Subject: [PATCH] [FIX #1602] Trim whitespace from passphrase during account recovery Currently account recovery includes whitespace on either side of the passphrase, preventing recovery of the desired account. We trim that whitespace in the account-recovery-fx --- src/status_im/ui/screens/accounts/recover/events.cljs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/status_im/ui/screens/accounts/recover/events.cljs b/src/status_im/ui/screens/accounts/recover/events.cljs index ae852a3388..09405e98bc 100644 --- a/src/status_im/ui/screens/accounts/recover/events.cljs +++ b/src/status_im/ui/screens/accounts/recover/events.cljs @@ -16,7 +16,10 @@ (reg-fx ::recover-account-fx (fn [[passphrase password]] - (status/recover-account passphrase password #(dispatch [:account-recovered %])))) + (status/recover-account + (str/trim passphrase) + password + #(dispatch [:account-recovered %])))) ;;;; Handlers @@ -45,4 +48,3 @@ :recover-account (fn [_ [_ passphrase password]] {::recover-account-fx [passphrase password]})) -