Add safemode trigger to card setup function
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
038f2cc130
commit
6d63232ecb
1 changed files with 7 additions and 3 deletions
|
@ -10,9 +10,13 @@ export default class CardSetupFunction {
|
|||
public static async Execute() {
|
||||
if (await Config.GetValue('safemode') == "true") return;
|
||||
|
||||
try {
|
||||
await this.ClearDatabase();
|
||||
await this.ReadSeries();
|
||||
await this.ReadCards();
|
||||
} catch {
|
||||
await Config.SetValue('safemode', 'true');
|
||||
}
|
||||
}
|
||||
|
||||
private static async ClearDatabase() {
|
||||
|
|
Loading…
Reference in a new issue