From fe81e4d38439560514fbd9c883b9a1aa99c9219e Mon Sep 17 00:00:00 2001 From: heapwolf Date: Mon, 15 Apr 2024 23:07:55 +0200 Subject: [PATCH] reset --- socket.ini | 2 +- src/index.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/socket.ini b/socket.ini index 0553235..0ab7555 100644 --- a/socket.ini +++ b/socket.ini @@ -29,7 +29,7 @@ ; copy_map = src/mapping.ini ; An list of environment variables, separated by commas. -env = HOME, USER, TMPDIR, PWD, DEBUG, UNION_RESET +env = HOME, USER, TMPDIR, PWD, DEBUG, RESET ; Advanced Compiler Settings (ie C++ compiler -02, -03, etc). flags = -O3 diff --git a/src/index.js b/src/index.js index 049613b..74e22e8 100644 --- a/src/index.js +++ b/src/index.js @@ -349,10 +349,11 @@ class AppView extends Tonic { } async initData () { - if (process.env.UNION_RESET === '1') { + if (process.env.RESET === '1') { await rm(path.DATA) const databases = await window.indexedDB.databases() for (const { name } of databases) await Indexed.drop(name) + process.exit(0) } this.db = {