Make keycard login faster

Signed-off-by: Dmitry Novotochinov <dmitry.novot@gmail.com>
This commit is contained in:
Dmitry Novotochinov 2019-03-11 13:03:28 +03:00
parent cf0afbca14
commit f91a69c6b0
No known key found for this signature in database
GPG Key ID: 43D1DAF5AD39C927
3 changed files with 11 additions and 8 deletions

View File

@ -54,7 +54,7 @@
"react-native-safe-area-view": "0.9.0",
"react-native-securerandom": "git+https://github.com/status-im/react-native-securerandom.git#0.1.1-2",
"react-native-splash-screen": "3.1.1",
"react-native-status-keycard": "git+https://github.com/status-im/react-native-status-keycard.git#v2.3.9",
"react-native-status-keycard": "git+https://github.com/status-im/react-native-status-keycard.git#v2.3.10",
"react-native-svg": "6.5.2",
"react-native-tcp": "git+https://github.com/status-im/react-native-tcp.git#v3.3.0-1-status",
"react-native-udp": "git+https://github.com/status-im/react-native-udp.git#2.3.1-1",

View File

@ -5845,9 +5845,9 @@ react-native-splash-screen@3.1.1:
resolved "https://registry.yarnpkg.com/react-native-splash-screen/-/react-native-splash-screen-3.1.1.tgz#1a4e46c9fdce53ff52af2a2cb4181788c4e30b30"
integrity sha512-PU2YocOSGbLjL9Vgcq/cwMNuHHKNjjuPpa1IPMuWo+6EB/fSZ5VOmxSa7+eucQe3631s3NhGuk3eHKahU03a4Q==
"react-native-status-keycard@git+https://github.com/status-im/react-native-status-keycard.git#v2.3.9":
version "2.3.9"
resolved "git+https://github.com/status-im/react-native-status-keycard.git#d6378e434fcf06ca23f8c373a4d44d5a69c23db5"
"react-native-status-keycard@git+https://github.com/status-im/react-native-status-keycard.git#v2.3.10":
version "2.3.10"
resolved "git+https://github.com/status-im/react-native-status-keycard.git#a6da0a7889fdbc8cdf61771cf1b989c5cfb14b08"
react-native-svg@6.5.2:
version "6.5.2"

View File

@ -701,10 +701,13 @@
(fx/defn wait-for-card-tap
[{:keys [db] :as cofx}]
(let [card-connected? (get-in db [:hardwallet :card-connected?])]
(if card-connected?
(login-with-keycard cofx false)
(fx/merge cofx
{:db (-> db
(assoc-in [:hardwallet :on-card-read] :hardwallet/login-with-keycard))}
(navigation/navigate-to-cofx :hardwallet-connect nil)))
(navigation/navigate-to-cofx :hardwallet-connect nil)))))
; PIN enter steps:
; login - PIN is used to login