{"action":"created","issue":{"url":"https://api.github.com/repos/bredikhin/barrels/issues/30","labels_url":"https://api.github.com/repos/bredikhin/barrels/issues/30/labels{/name}","comments_url":"https://api.github.com/repos/bredikhin/barrels/issues/30/comments","events_url":"https://api.github.com/repos/bredikhin/barrels/issues/30/events","html_url":"https://github.com/bredikhin/barrels/issues/30","id":93367246,"number":30,"title":"Model's Capital Attribute - Nulled attr after populating the DB","user":{"login":"OmarTrigui","id":7053612,"avatar_url":"https://avatars.githubusercontent.com/u/7053612?v=3","gravatar_id":"","url":"https://api.github.com/users/OmarTrigui","html_url":"https://github.com/OmarTrigui","followers_url":"https://api.github.com/users/OmarTrigui/followers","following_url":"https://api.github.com/users/OmarTrigui/following{/other_user}","gists_url":"https://api.github.com/users/OmarTrigui/gists{/gist_id}","starred_url":"https://api.github.com/users/OmarTrigui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OmarTrigui/subscriptions","organizations_url":"https://api.github.com/users/OmarTrigui/orgs","repos_url":"https://api.github.com/users/OmarTrigui/repos","events_url":"https://api.github.com/users/OmarTrigui/events{/privacy}","received_events_url":"https://api.github.com/users/OmarTrigui/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-06T20:16:36Z","updated_at":"2015-07-08T13:43:18Z","closed_at":null,"body":"I have used Barrels to populate my MongoDB Database ( via Waterline ORM )\r\nLet's suppose that we have an association between my two models (Collections) via the attr \"xattr\".\r\n\r\nWhile populating the DB using the prepared fixtures, i get the document \"xattr\" nulled when it's not capital,\r\nbut filled et converted into an ObjectId when it's capitalized ...\r\n\r\nIs it a bug, or can i get more details about this problem ?\r\nThanx\r\n"},"comment":{"url":"https://api.github.com/repos/bredikhin/barrels/issues/comments/119583022","html_url":"https://github.com/bredikhin/barrels/issues/30#issuecomment-119583022","issue_url":"https://api.github.com/repos/bredikhin/barrels/issues/30","id":119583022,"user":{"login":"bredikhin","id":1322727,"avatar_url":"https://avatars.githubusercontent.com/u/1322727?v=3","gravatar_id":"","url":"https://api.github.com/users/bredikhin","html_url":"https://github.com/bredikhin","followers_url":"https://api.github.com/users/bredikhin/followers","following_url":"https://api.github.com/users/bredikhin/following{/other_user}","gists_url":"https://api.github.com/users/bredikhin/gists{/gist_id}","starred_url":"https://api.github.com/users/bredikhin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bredikhin/subscriptions","organizations_url":"https://api.github.com/users/bredikhin/orgs","repos_url":"https://api.github.com/users/bredikhin/repos","events_url":"https://api.github.com/users/bredikhin/events{/privacy}","received_events_url":"https://api.github.com/users/bredikhin/received_events","type":"User","site_admin":false},"created_at":"2015-07-08T13:43:18Z","updated_at":"2015-07-08T13:43:18Z","body":"According to the [Sails' docs](http://sailsjs.org/documentation/concepts/models-and-orm/associations/one-to-many#?onetomany-example), your model should be all lowercase. Also, if these fixtures are the contents of your JSON files, you shouldn't hardcode the ids, as well as the timestamps, Mongo will do it for you. And association mapping can be done using the position in your fixture file (which is just 1 for your example)."}}