move registration.js to ts
parent
0d4059ccb1
commit
6334f7cb45
@ -1,28 +0,0 @@
|
|||||||
/* global storage, Whisper */
|
|
||||||
|
|
||||||
// eslint-disable-next-line func-names
|
|
||||||
(function() {
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
Whisper.Registration = {
|
|
||||||
markEverDone() {
|
|
||||||
storage.put('chromiumRegistrationDoneEver', '');
|
|
||||||
},
|
|
||||||
markDone() {
|
|
||||||
this.markEverDone();
|
|
||||||
storage.put('chromiumRegistrationDone', '');
|
|
||||||
},
|
|
||||||
isDone() {
|
|
||||||
return storage.get('chromiumRegistrationDone') === '';
|
|
||||||
},
|
|
||||||
everDone() {
|
|
||||||
return (
|
|
||||||
storage.get('chromiumRegistrationDoneEver') === '' ||
|
|
||||||
storage.get('chromiumRegistrationDone') === ''
|
|
||||||
);
|
|
||||||
},
|
|
||||||
remove() {
|
|
||||||
storage.remove('chromiumRegistrationDone');
|
|
||||||
},
|
|
||||||
};
|
|
||||||
})();
|
|
@ -0,0 +1,21 @@
|
|||||||
|
function markEverDone() {
|
||||||
|
storage.put('chromiumRegistrationDoneEver', '');
|
||||||
|
}
|
||||||
|
function markDone() {
|
||||||
|
this.markEverDone();
|
||||||
|
storage.put('chromiumRegistrationDone', '');
|
||||||
|
}
|
||||||
|
function isDone() {
|
||||||
|
return storage.get('chromiumRegistrationDone') === '';
|
||||||
|
}
|
||||||
|
function everDone() {
|
||||||
|
return (
|
||||||
|
storage.get('chromiumRegistrationDoneEver') === '' ||
|
||||||
|
storage.get('chromiumRegistrationDone') === ''
|
||||||
|
);
|
||||||
|
}
|
||||||
|
function remove() {
|
||||||
|
storage.remove('chromiumRegistrationDone');
|
||||||
|
}
|
||||||
|
|
||||||
|
export const Registration = { markEverDone, markDone, isDone, everDone, remove };
|
Loading…
Reference in New Issue