Skip to content

Commit

Permalink
Fixed printing wrong model name if debug is active.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrbatista committed Nov 17, 2015
1 parent d8d3752 commit e868a4e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions read-only.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ module.exports = function(Model, options) {
}
var properties = (Object.keys(options).length) ? options : null;
if (properties) {
debug('Creating %s : Read only properties are %j', 'modelInstance.Model.modelName', properties);
debug('Creating %s : Read only properties are %j', Model.modelName, properties);
Object.keys(properties).forEach(function(key) {
debug('The \'%s\' property is readonly, removing incoming data', key);
debug('The \'%s\' property is read only, removing incoming data', key);
delete body[key];
});
next();
Expand Down

0 comments on commit e868a4e

Please sign in to comment.