VeryModel
VeryModel copied to clipboard
submodals with static throw error on create
var MyModel = new verymodel.Model({
id: {type: 'string', static: true},
owner: {model: {
owner_id: {type: 'string', static: true}
}}
});
var model = MyModel.create({
id: 'foobar',
owner: {
owner_id: 'fizzbuzz'
}
});
// Error: Cannot set static values
// at Object.owner_id (…/node_modules/verymodel/lib/model.js:347:27)
Identified in https://github.com/cloudflare/node-cloudflare/issues/2