Skip to content

Commit

Permalink
Merge pull request #48 from nicjansma/master
Browse files Browse the repository at this point in the history
fromArray(): Always ensure _originalData is available
  • Loading branch information
xavierlacot committed May 26, 2015
2 parents f6a30f5 + 6c23fa9 commit 3964d8f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion joli.js
Expand Up @@ -794,8 +794,8 @@ var joliCreator = function() {
fromArray: function(data) {
var wasNew = this.isNew ? this.isNew() : true;

this._originalData = this._originalData || {};
if (typeof data.id !== 'undefined') {
this._originalData = this._originalData || {};
this.isNew = function() {
return false;
};
Expand Down

0 comments on commit 3964d8f

Please sign in to comment.