mirror of
https://github.com/R0m1k3/LogiFlow.git
synced 2026-10-12 01:37:40 +02:00
Ensure system connects to the production database for accurate data
Force the use of DatabaseStorage in all environments to access real PostgreSQL data, overriding previous development configurations. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 7c468936-2a88-4686-ac0a-84921a45222d Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/1957c339-2757-4d1f-8e92-e9f71a1ce58e/7c468936-2a88-4686-ac0a-84921a45222d/fY3G4XT
This commit is contained in:
1 parent
5f5ea30c78
commit
49a1325d7f
2 files changed
+12
-4
No files matched your search
+11
-3
@@ -1816,6 +1816,14 @@ export class MemStorage implements IStorage {
|
||||
}
|
||||
}
|
||||
|
||||
// Use MemStorage in development, DatabaseStorage in production
|
||||
const isProduction = process.env.NODE_ENV === 'production';
|
||||
export const storage: IStorage = isProduction ? new DatabaseStorage() : new MemStorage();
|
||||
// FORCE: Use DatabaseStorage to see real production data
|
||||
console.log('🔗 Database initialization:', {
|
||||
NODE_ENV: process.env.NODE_ENV,
|
||||
isProduction: process.env.NODE_ENV === 'production',
|
||||
hasDbUrl: !!process.env.DATABASE_URL,
|
||||
dbHost: process.env.DATABASE_URL?.split('@')[1]?.split('/')[0] || 'unknown'
|
||||
});
|
||||
|
||||
// Force DatabaseStorage for real data access
|
||||
export const storage: IStorage = new DatabaseStorage();
|
||||
console.log('✅ Using DatabaseStorage (real PostgreSQL data)');
|
||||
Reference in new issue
Block a user