Skip to content

Instantly share code, notes, and snippets.

@shubik
Created June 2, 2013 00:46
Show Gist options
  • Save shubik/5692207 to your computer and use it in GitHub Desktop.
Save shubik/5692207 to your computer and use it in GitHub Desktop.
Test
var UserModel = require('./_user_model'),
user = new UserModel();
user(function(model) {
model.set({
name: 'Shubik',
email: '[email protected]'
});
model.save()(function(model) {
console.log('New user model saved', model.toJSON());
}, function(err) {
console.log(err.toString());
});
}, function(err) {
console.log(err.toString());
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment