mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-16 07:57:33 +08:00
user need input current pin code when disable application lock
This commit is contained in:
@@ -79,6 +79,13 @@ function decryptToken() {
|
||||
sessionStorage.removeItem(appLockSecretSessionStorageKey);
|
||||
}
|
||||
|
||||
function isCorrectPinCode(pinCode) {
|
||||
const secret = getAppLockSecret(pinCode);
|
||||
const currentSecret = sessionStorage.getItem(appLockSecretSessionStorageKey);
|
||||
|
||||
return secret === currentSecret;
|
||||
}
|
||||
|
||||
function updateToken(token) {
|
||||
if (utils.isString(token)) {
|
||||
if (settings.isEnableApplicationLock()) {
|
||||
@@ -125,6 +132,7 @@ export default {
|
||||
unlockToken,
|
||||
encryptToken,
|
||||
decryptToken,
|
||||
isCorrectPinCode,
|
||||
updateToken,
|
||||
updateUserInfo,
|
||||
updateTokenAndUserInfo,
|
||||
|
||||
Reference in New Issue
Block a user