Skip to content

Commit 9e62b06

Browse files
committed
feat: Add marshaling support for the ObjectID data type. Values will be marshaled as strings.
1 parent 35adef8 commit 9e62b06

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

lib/postgresql.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,10 @@ PostgreSQL.prototype.toColumnValue = function(prop, val) {
488488
params: [val.lng, val.lat]
489489
});
490490
}
491+
492+
if (prop.type.name.toLowerCase() === 'ObjectID'.toLowerCase()) {
493+
return String(val);
494+
}
491495

492496
return val;
493497
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "loopback-connector-postgresql",
3-
"version": "2.4.4",
3+
"version": "2.4.5",
44
"description": "Loopback PostgreSQL Connector",
55
"keywords": [
66
"StrongLoop",

0 commit comments

Comments
 (0)