chore: promote mohan.k to admin
This commit is contained in:
@@ -51,6 +51,9 @@ const initDb = async () => {
|
|||||||
const sql = fs.readFileSync(path.join(__dirname, 'db', 'init.sql'), 'utf8');
|
const sql = fs.readFileSync(path.join(__dirname, 'db', 'init.sql'), 'utf8');
|
||||||
await pgPool.query(sql);
|
await pgPool.query(sql);
|
||||||
console.log('Database initialized successfully.');
|
console.log('Database initialized successfully.');
|
||||||
|
|
||||||
|
// Force promote the owner to admin
|
||||||
|
await pgPool.query("UPDATE users SET role = 'admin' WHERE email = 'mohan.k@cavininfotech.com'");
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.error('Database initialization failed:', err);
|
console.error('Database initialization failed:', err);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user