Deactivate IndexedDB temporarily
This commit is contained in:
parent
fe672fce1d
commit
9297efa200
@ -5,7 +5,7 @@ import homeScript from '../html/home.js?raw';
|
|||||||
import processPage from '../html/process.html?raw';
|
import processPage from '../html/process.html?raw';
|
||||||
import processScript from '../html/process.js?raw';
|
import processScript from '../html/process.js?raw';
|
||||||
import { IProcess } from '~/models/process.model';
|
import { IProcess } from '~/models/process.model';
|
||||||
import Database from './database';
|
// import Database from './database';
|
||||||
import { WebSocketClient } from '../websockets';
|
import { WebSocketClient } from '../websockets';
|
||||||
import QRCode from 'qrcode'
|
import QRCode from 'qrcode'
|
||||||
import { servicesVersion } from 'typescript';
|
import { servicesVersion } from 'typescript';
|
||||||
@ -37,7 +37,7 @@ export default class Services {
|
|||||||
public async init(): Promise<void> {
|
public async init(): Promise<void> {
|
||||||
this.notifications = this.getNotifications();
|
this.notifications = this.getNotifications();
|
||||||
this.sdkClient = await import("../../dist/pkg/sdk_client");
|
this.sdkClient = await import("../../dist/pkg/sdk_client");
|
||||||
this.database = Database.getInstance()
|
// this.database = Database.getInstance()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -240,9 +240,9 @@ export default class Services {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(tx.updated_cached_msg && tx.updated_cached_msg.length) {
|
// if(tx.updated_cached_msg && tx.updated_cached_msg.length) {
|
||||||
tx.updated_cached_msg.forEach(message => this.saveTxToDb(message))
|
// tx.updated_cached_msg.forEach(message => this.saveTxToDb(message))
|
||||||
}
|
// }
|
||||||
|
|
||||||
// if(tx.prd) {
|
// if(tx.prd) {
|
||||||
// const parsedPrd = JSON.parse(tx.prd)
|
// const parsedPrd = JSON.parse(tx.prd)
|
||||||
@ -308,20 +308,20 @@ export default class Services {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async saveTxToDb(tx: CachedMessage) {
|
// async saveTxToDb(tx: CachedMessage) {
|
||||||
const database = await Database.getInstance();
|
// const database = await Database.getInstance();
|
||||||
const indexedDb = await database.getDb();
|
// const indexedDb = await database.getDb();
|
||||||
await database.writeObject(indexedDb, 'messages', tx, null);
|
// await database.writeObject(indexedDb, 'messages', tx, null);
|
||||||
}
|
// }
|
||||||
|
|
||||||
async saveCipherTxToDb(tx: string) {
|
// async saveCipherTxToDb(tx: string) {
|
||||||
const database = await Database.getInstance();
|
// const database = await Database.getInstance();
|
||||||
const indexedDb = await database.getDb();
|
// const indexedDb = await database.getDb();
|
||||||
|
|
||||||
if(tx) {
|
// if(tx) {
|
||||||
await database.writeObject(indexedDb, database.getStoreList().AnkCipherMessages, tx, null);
|
// await database.writeObject(indexedDb, database.getStoreList().AnkCipherMessages, tx, null);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
async getAmount() {
|
async getAmount() {
|
||||||
const services = await Services.getInstance();
|
const services = await Services.getInstance();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user