{"action":"created","issue":{"url":"https://api.github.com/repos/balderdashy/waterline/issues/1040","labels_url":"https://api.github.com/repos/balderdashy/waterline/issues/1040/labels{/name}","comments_url":"https://api.github.com/repos/balderdashy/waterline/issues/1040/comments","events_url":"https://api.github.com/repos/balderdashy/waterline/issues/1040/events","html_url":"https://github.com/balderdashy/waterline/issues/1040","id":84914592,"number":1040,"title":"[TypeError: Cannot read property 'collections' of undefined] when calling model.collection.add","user":{"login":"joeandrews","id":4138549,"avatar_url":"https://avatars.githubusercontent.com/u/4138549?v=3","gravatar_id":"","url":"https://api.github.com/users/joeandrews","html_url":"https://github.com/joeandrews","followers_url":"https://api.github.com/users/joeandrews/followers","following_url":"https://api.github.com/users/joeandrews/following{/other_user}","gists_url":"https://api.github.com/users/joeandrews/gists{/gist_id}","starred_url":"https://api.github.com/users/joeandrews/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joeandrews/subscriptions","organizations_url":"https://api.github.com/users/joeandrews/orgs","repos_url":"https://api.github.com/users/joeandrews/repos","events_url":"https://api.github.com/users/joeandrews/events{/privacy}","received_events_url":"https://api.github.com/users/joeandrews/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-06-04T05:03:32Z","updated_at":"2015-06-04T15:25:46Z","closed_at":null,"body":"With sails v0.11.0 and latest sails-mongo I am getting this error. I think the error is coming from waterline any ideas on where to start ?"},"comment":{"url":"https://api.github.com/repos/balderdashy/waterline/issues/comments/108934814","html_url":"https://github.com/balderdashy/waterline/issues/1040#issuecomment-108934814","issue_url":"https://api.github.com/repos/balderdashy/waterline/issues/1040","id":108934814,"user":{"login":"dmarcelino","id":1280446,"avatar_url":"https://avatars.githubusercontent.com/u/1280446?v=3","gravatar_id":"","url":"https://api.github.com/users/dmarcelino","html_url":"https://github.com/dmarcelino","followers_url":"https://api.github.com/users/dmarcelino/followers","following_url":"https://api.github.com/users/dmarcelino/following{/other_user}","gists_url":"https://api.github.com/users/dmarcelino/gists{/gist_id}","starred_url":"https://api.github.com/users/dmarcelino/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmarcelino/subscriptions","organizations_url":"https://api.github.com/users/dmarcelino/orgs","repos_url":"https://api.github.com/users/dmarcelino/repos","events_url":"https://api.github.com/users/dmarcelino/events{/privacy}","received_events_url":"https://api.github.com/users/dmarcelino/received_events","type":"User","site_admin":false},"created_at":"2015-06-04T15:25:46Z","updated_at":"2015-06-04T15:25:46Z","body":"I feared that wasn't the root issue...\r\n\r\nRegarding the stack trace, can you try logging the exception earlier? For example:\r\n```js\r\nreturn user.save(function(err){\r\n  if(err) console.error('save failed:', err);\r\n});\r\n```"}}