Updates
This commit is contained in:
@@ -13,7 +13,7 @@ import grabDSQLConnection from "../utils/grab-dsql-connection";
|
||||
* @returns {Promise<object|null>}
|
||||
*/
|
||||
(async () => {
|
||||
const CONNECTION = grabDSQLConnection();
|
||||
const CONNECTION = await grabDSQLConnection();
|
||||
|
||||
try {
|
||||
const result = await CONNECTION.query(
|
||||
@@ -24,7 +24,7 @@ import grabDSQLConnection from "../utils/grab-dsql-connection";
|
||||
console.log("Connection query ERROR =>", error.message);
|
||||
global.ERROR_CALLBACK?.(`Error Checking DB`, error as Error);
|
||||
} finally {
|
||||
CONNECTION?.end();
|
||||
await CONNECTION?.end();
|
||||
process.exit();
|
||||
}
|
||||
})();
|
||||
|
||||
@@ -13,7 +13,7 @@ import grabDSQLConnection from "../utils/grab-dsql-connection";
|
||||
* @returns {Promise<object|null>}
|
||||
*/
|
||||
(async () => {
|
||||
const CONNECTION = grabDSQLConnection({ noDb: true });
|
||||
const CONNECTION = await grabDSQLConnection({ noDb: true });
|
||||
|
||||
/**
|
||||
* Switch Database
|
||||
@@ -32,7 +32,7 @@ import grabDSQLConnection from "../utils/grab-dsql-connection";
|
||||
error as Error
|
||||
);
|
||||
} finally {
|
||||
CONNECTION?.end();
|
||||
await CONNECTION?.end();
|
||||
process.exit();
|
||||
}
|
||||
})();
|
||||
|
||||
@@ -14,7 +14,7 @@ import grabSQLKeyName from "../utils/grab-sql-key-name";
|
||||
* @returns {Promise<object|null>}
|
||||
*/
|
||||
(async () => {
|
||||
const CONNECTION = grabDSQLConnection();
|
||||
const CONNECTION = await grabDSQLConnection();
|
||||
|
||||
try {
|
||||
const result = await CONNECTION.query(
|
||||
@@ -48,7 +48,7 @@ import grabSQLKeyName from "../utils/grab-sql-key-name";
|
||||
} catch (error: any) {
|
||||
global.ERROR_CALLBACK?.(`Error Updating SSL Users`, error as Error);
|
||||
} finally {
|
||||
CONNECTION.end();
|
||||
await CONNECTION?.end();
|
||||
process.exit();
|
||||
}
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user