u
This commit is contained in:
@@ -5,6 +5,7 @@ import { clearCachedCompanyUsers, clearCachedUser } from '../api/middleware/auth
|
||||
import { clearDeletedCompany, setUserCompany } from '../api/sse.js';
|
||||
|
||||
const storeLog = createLogger('libstore');
|
||||
const schemaLog = createLogger('schema');
|
||||
|
||||
let provider;
|
||||
let store;
|
||||
@@ -146,7 +147,12 @@ export async function getStore() {
|
||||
if (!connecting) {
|
||||
connecting = (async () => {
|
||||
provider = createProvider();
|
||||
await provider.initialize();
|
||||
try {
|
||||
await provider.initialize((msg) => schemaLog.info(msg));
|
||||
} catch (err) {
|
||||
schemaLog.error('Database schema initialization failed:', err);
|
||||
throw err;
|
||||
}
|
||||
store = wrapStoreWithTiming(await new LibDashStore(provider));
|
||||
return store;
|
||||
})().finally(() => {
|
||||
|
||||
@@ -67,6 +67,7 @@ const DIVISION_COLORS = {
|
||||
vfs: chalk.hex('#14b8a6'), // Teal
|
||||
event: chalk.hex('#a855f7'), // Violet
|
||||
backup: chalk.hex('#06b6d4'), // Cyan
|
||||
schema: chalk.hex('#0ea5e9'), // Sky blue
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user