@spfn/core 0.1.0-alpha.22 → 0.1.0-alpha.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/db/index.js +2 -2
- package/dist/db/index.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/server/index.js +2 -2
- package/dist/server/index.js.map +1 -1
- package/package.json +1 -1
package/dist/db/index.js
CHANGED
|
@@ -1067,7 +1067,7 @@ async function createDatabaseFromEnv(options) {
|
|
|
1067
1067
|
hasUrl: !!process.env.DATABASE_URL,
|
|
1068
1068
|
hasReplicaUrl: !!process.env.DATABASE_REPLICA_URL
|
|
1069
1069
|
});
|
|
1070
|
-
|
|
1070
|
+
throw new Error(`Database connection failed: ${message}`, { cause: error });
|
|
1071
1071
|
}
|
|
1072
1072
|
}
|
|
1073
1073
|
|
|
@@ -1149,7 +1149,7 @@ async function initDatabase(options) {
|
|
|
1149
1149
|
const message = error instanceof Error ? error.message : "Unknown error";
|
|
1150
1150
|
dbLogger3.error("Database connection failed", { error: message });
|
|
1151
1151
|
await closeDatabase();
|
|
1152
|
-
|
|
1152
|
+
throw new Error(`Database connection test failed: ${message}`, { cause: error });
|
|
1153
1153
|
}
|
|
1154
1154
|
} else {
|
|
1155
1155
|
dbLogger3.warn("No database configuration found");
|