mirror of
https://github.com/standardnotes/mobile.git
synced 2026-04-21 14:46:55 -04:00
Authenticate onUnmount, 3.0.2 build 2
This commit is contained in:
@@ -102,7 +102,7 @@ android {
|
||||
minSdkVersion rootProject.ext.minSdkVersion
|
||||
targetSdkVersion rootProject.ext.targetSdkVersion
|
||||
|
||||
versionCode 3000020
|
||||
versionCode 3000021
|
||||
versionName "3.0.2"
|
||||
|
||||
multiDexEnabled true
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1</string>
|
||||
<string>2</string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSAppTransportSecurity</key>
|
||||
|
||||
6
package-lock.json
generated
6
package-lock.json
generated
@@ -11746,9 +11746,9 @@
|
||||
"integrity": "sha1-ATl5IuX2Ls8whFUiyVxP4dJefU4="
|
||||
},
|
||||
"standard-file-js": {
|
||||
"version": "0.3.40",
|
||||
"resolved": "https://registry.npmjs.org/standard-file-js/-/standard-file-js-0.3.40.tgz",
|
||||
"integrity": "sha512-1gxRw3MfNLK9tvmzyht77/GGSOwN3la0Z1NrZeAA1+Z8KClngdhulR2SHS1DXT9jwhIC2wcowu/W1R5P8cIhIA=="
|
||||
"version": "0.3.41",
|
||||
"resolved": "https://registry.npmjs.org/standard-file-js/-/standard-file-js-0.3.41.tgz",
|
||||
"integrity": "sha512-K8d26JaUZS9wRuonUQSl+7/3ArfXp3eUCwd+CgqHcgz9nLxdLR+slzjyrdN5VzHz9pZ64imOdYgiARdKnQtN6g=="
|
||||
},
|
||||
"static-extend": {
|
||||
"version": "0.1.2",
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
"react-navigation-header-buttons": "^2.1.1",
|
||||
"regenerator": "^0.13.3",
|
||||
"sn-models": "0.1.13",
|
||||
"standard-file-js": "0.3.40"
|
||||
"standard-file-js": "0.3.41"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-jest": "^23.6.0",
|
||||
|
||||
@@ -63,6 +63,15 @@ export default class Authenticate extends Abstract {
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
|
||||
// Typically there should be no way to exit this window if it doesn't have a cancel option.
|
||||
// However, on Android, you can press the hardware back button to dismiss it. We want to notify
|
||||
// caller that this screen has unmounted
|
||||
let onUnmount = this.getProp("onUnmount");
|
||||
if(onUnmount) {
|
||||
onUnmount();
|
||||
}
|
||||
|
||||
super.componentWillUnmount();
|
||||
ApplicationState.get().removeStateObserver(this.stateObserver);
|
||||
}
|
||||
|
||||
@@ -217,10 +217,12 @@ export default class Root extends Abstract {
|
||||
onSuccess: () => {
|
||||
authProps.onAuthenticate();
|
||||
this.authenticationInProgress = false;
|
||||
|
||||
if(this.dataLoaded) {
|
||||
Sync.get().sync();
|
||||
}
|
||||
},
|
||||
onUnmount: () => {
|
||||
this.authenticationInProgress = false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user