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

Commit 6b3b639c by Sascha Depold

check if values are properties of passes object

it seems that mysql 2.0.0-alpha3 adds functions to the result sets which were added to the dao instances and broke the specs. the check makes sure, that only the actual values are added to the dao instance
1 parent 2a3cf738
Showing with 2 additions and 2 deletions
......@@ -259,12 +259,12 @@ module.exports = (function() {
// private
var initAttributes = function(values) {
var self = this
// add all passed values to the dao and store the attribute names in this.attributes
for (var key in values) {
if (values.hasOwnProperty(key)) {
this.addAttribute(key, values[key])
}
}
// set id to null if not passed as value
// a newly created dao has no id
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!