Add safemode trigger to card setup function
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Ethan Lane 2023-11-12 18:53:38 +00:00
parent 038f2cc130
commit 6d63232ecb

View file

@ -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() {