@vue-skuilder/db 0.2.12 → 0.2.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/index.js +5 -0
- package/dist/core/index.js.map +1 -1
- package/dist/core/index.mjs +5 -0
- package/dist/core/index.mjs.map +1 -1
- package/dist/impl/couch/index.js +13 -0
- package/dist/impl/couch/index.js.map +1 -1
- package/dist/impl/couch/index.mjs +13 -0
- package/dist/impl/couch/index.mjs.map +1 -1
- package/dist/impl/static/index.js +5 -0
- package/dist/impl/static/index.js.map +1 -1
- package/dist/impl/static/index.mjs +5 -0
- package/dist/impl/static/index.mjs.map +1 -1
- package/dist/index.d.cts +6 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +46 -27
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +46 -27
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/impl/common/BaseUserDB.ts +13 -0
- package/src/impl/couch/CouchDBSyncStrategy.ts +17 -0
- package/src/study/services/EloService.ts +20 -8
- package/src/study/services/ResponseProcessor.ts +62 -50
package/dist/impl/couch/index.js
CHANGED
|
@@ -7524,6 +7524,11 @@ Currently logged-in as ${this._username}.`
|
|
|
7524
7524
|
return { ok: true };
|
|
7525
7525
|
}
|
|
7526
7526
|
const ret = await this.syncStrategy.logout();
|
|
7527
|
+
try {
|
|
7528
|
+
localStorage.removeItem("sk-guest-uuid");
|
|
7529
|
+
} catch (e) {
|
|
7530
|
+
logger.warn("localStorage not available (Node.js environment):", e);
|
|
7531
|
+
}
|
|
7527
7532
|
this._username = await this.syncStrategy.getCurrentUsername();
|
|
7528
7533
|
await this.init();
|
|
7529
7534
|
return ret;
|
|
@@ -8899,6 +8904,14 @@ var init_CouchDBSyncStrategy = __esm({
|
|
|
8899
8904
|
} else {
|
|
8900
8905
|
logger.info("No documents to migrate from funnel account");
|
|
8901
8906
|
}
|
|
8907
|
+
try {
|
|
8908
|
+
await oldLocalDB.destroy();
|
|
8909
|
+
logger.info(`Destroyed consumed guest DB for ${oldUsername}`);
|
|
8910
|
+
} catch (destroyErr) {
|
|
8911
|
+
logger.warn(
|
|
8912
|
+
`Failed to destroy consumed guest DB for ${oldUsername} (non-fatal): ${destroyErr instanceof Error ? destroyErr.message : String(destroyErr)}`
|
|
8913
|
+
);
|
|
8914
|
+
}
|
|
8902
8915
|
return { success: true };
|
|
8903
8916
|
} catch (error) {
|
|
8904
8917
|
logger.error("Migration failed:", error);
|