Permalink
Browse files

Update lib/adapters/postgres.js

fix to add quotes around key so that it works for mixed-case correctly
  • Loading branch information...
1 parent 4510008 commit f3bafd7bf984cf232d5d55026d047405297a68a0 @clarktlaugh clarktlaugh committed Sep 30, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/adapters/postgres.js
@@ -237,7 +237,7 @@ PG.prototype.toFilter = function (model, filter) {
fields.push('"' + key + '" IS ' + filterValue);
} else if (conds[key].constructor.name === 'Object') {
var condType = Object.keys(conds[key])[0];
- var sqlCond = key;
+ var sqlCond = '"' + key + '"';
switch (condType) {
case 'gt':
sqlCond += ' > ';

0 comments on commit f3bafd7

Please sign in to comment.