不要怂,就是干,撸起袖子干!

Commit 67348fc4 by Sascha Depold

Merge pull request #656 from echong/master

Fixing a bug in query generation where 'identifier' is being stored as the raw value of the 'id' rather than being wrapped in an object.
2 parents 32fa3034 96743a91
Showing with 1 additions and 1 deletions
......@@ -158,7 +158,7 @@ module.exports = (function() {
else if (this.isNewRecord) {
return this.QueryInterface.insert(this, this.QueryInterface.QueryGenerator.addSchema(this.__factory), values)
} else {
var identifier = this.__options.hasPrimaryKeys ? this.primaryKeyValues : this.id;
var identifier = this.__options.hasPrimaryKeys ? this.primaryKeyValues : { id: this.id };
if (identifier === null && this.__options.whereCollection !== null) {
identifier = this.__options.whereCollection;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!