chore: throttle switchversion
This commit is contained in:
parent
33eb89d2a7
commit
7752581470
@ -322,10 +322,12 @@ function assertHash(hash: string) {
|
||||
return true;
|
||||
}
|
||||
|
||||
let applyingUpdate = false;
|
||||
export function switchVersion(hash: string) {
|
||||
assertRelease();
|
||||
if (assertHash(hash)) {
|
||||
if (assertHash(hash) && !applyingUpdate) {
|
||||
logger('switchVersion: ' + hash);
|
||||
applyingUpdate = true;
|
||||
PushyModule.reloadUpdate({ hash });
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user