Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changed implementation of replacing undefined with DEFAULT already in…
… query compiler for every dialect.
- Loading branch information
Showing
9 changed files
with
32 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,7 +34,7 @@ var arrayString; | |
// to their 'raw' counterparts for use as a postgres parameter | ||
// note: you can override this function to provide your own conversion mechanism | ||
// for complex types, etc... | ||
var prepareValue = function (val, seen, valueForUndefined) { | ||
var prepareValue = function (val, seen /*, valueForUndefined*/) { | ||
if (val instanceof Buffer) { | ||
return val; | ||
} | ||
|
@@ -47,9 +47,6 @@ var prepareValue = function (val, seen, valueForUndefined) { | |
if (val === null) { | ||
return null; | ||
} | ||
if (val === undefined) { | ||
return valueForUndefined; | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
elhigu
Author
Member
|
||
} | ||
if (typeof val === 'object') { | ||
return prepareObject(val, seen); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@elhigu This caused #1423 Because the above if used to have
|| val === undefined