@oino-ts/db-postgresql 0.5.0 → 0.5.2
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.
|
@@ -213,7 +213,7 @@ class OINODbPostgresql extends db_1.OINODb {
|
|
|
213
213
|
else if (sqlValue === undefined) {
|
|
214
214
|
return undefined;
|
|
215
215
|
}
|
|
216
|
-
else if (((sqlType == "date")) && (typeof (sqlValue) == "string")) {
|
|
216
|
+
else if (((sqlType == "date")) && (typeof (sqlValue) == "string") && (sqlValue != "")) {
|
|
217
217
|
return new Date(sqlValue);
|
|
218
218
|
}
|
|
219
219
|
else {
|
|
@@ -210,7 +210,7 @@ export class OINODbPostgresql extends OINODb {
|
|
|
210
210
|
else if (sqlValue === undefined) {
|
|
211
211
|
return undefined;
|
|
212
212
|
}
|
|
213
|
-
else if (((sqlType == "date")) && (typeof (sqlValue) == "string")) {
|
|
213
|
+
else if (((sqlType == "date")) && (typeof (sqlValue) == "string") && (sqlValue != "")) {
|
|
214
214
|
return new Date(sqlValue);
|
|
215
215
|
}
|
|
216
216
|
else {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oino-ts/db-postgresql",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.2",
|
|
4
4
|
"description": "OINO TS package for using Postgresql databases.",
|
|
5
5
|
"author": "Matias Kiviniemi (pragmatta)",
|
|
6
6
|
"license": "MPL-2.0",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"module": "./dist/esm/index.js",
|
|
21
21
|
"types": "./dist/types/index.d.ts",
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@oino-ts/db": "0.5.
|
|
23
|
+
"@oino-ts/db": "0.5.2",
|
|
24
24
|
"pg": "^8.11.3"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
package/src/OINODbPostgresql.ts
CHANGED
|
@@ -227,7 +227,7 @@ export class OINODbPostgresql extends OINODb {
|
|
|
227
227
|
} else if (sqlValue === undefined) {
|
|
228
228
|
return undefined
|
|
229
229
|
|
|
230
|
-
} else if (((sqlType == "date")) && (typeof(sqlValue) == "string")) {
|
|
230
|
+
} else if (((sqlType == "date")) && (typeof(sqlValue) == "string") && (sqlValue != "")) {
|
|
231
231
|
return new Date(sqlValue)
|
|
232
232
|
|
|
233
233
|
} else {
|