Skip to content

Commit 8ecf962

Browse files
committed
dresende#29 - Allows null and undefined to be treated differently.
1 parent 3f145ee commit 8ecf962

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

lib/Dialects/postgresql.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,11 @@ exports.escapeId = function () {
1717
};
1818

1919
exports.escapeVal = function (val, timeZone) {
20-
if (val === undefined || val === null) {
21-
return 'NULL';
22-
}
20+
if (val === undefined){
21+
return 'DEFAULT';
22+
}else if(val === null){
23+
return 'NULL';
24+
}
2325

2426
if (Array.isArray(val)) {
2527
if (val.length === 1 && Array.isArray(val[0])) {

0 commit comments

Comments
 (0)