{"action":"opened","issue":{"url":"https://api.github.com/repos/hacksparrow/mongoose-pages/issues/7","labels_url":"https://api.github.com/repos/hacksparrow/mongoose-pages/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/hacksparrow/mongoose-pages/issues/7/comments","events_url":"https://api.github.com/repos/hacksparrow/mongoose-pages/issues/7/events","html_url":"https://github.com/hacksparrow/mongoose-pages/issues/7","id":113243586,"number":7,"title":"lean option?","user":{"login":"priley86","id":4237045,"avatar_url":"https://avatars.githubusercontent.com/u/4237045?v=3","gravatar_id":"","url":"https://api.github.com/users/priley86","html_url":"https://github.com/priley86","followers_url":"https://api.github.com/users/priley86/followers","following_url":"https://api.github.com/users/priley86/following{/other_user}","gists_url":"https://api.github.com/users/priley86/gists{/gist_id}","starred_url":"https://api.github.com/users/priley86/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/priley86/subscriptions","organizations_url":"https://api.github.com/users/priley86/orgs","repos_url":"https://api.github.com/users/priley86/repos","events_url":"https://api.github.com/users/priley86/events{/privacy}","received_events_url":"https://api.github.com/users/priley86/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-25T18:54:23Z","updated_at":"2015-10-25T18:54:23Z","closed_at":null,"body":"Thanks for writing this... I am curious if anyone would like to see a lean option for performance reasons /extendability with plain old javascript objects?\r\nhttp://mongoosejs.com/docs/api.html#query_Query-lean\r\n\r\nAs it exists, the mongoose documents array returned is not extendable unless lean is specified...\r\nhttp://stackoverflow.com/questions/7503450/how-do-you-turn-a-mongoose-document-into-a-plain-object\r\n\r\nThis could be useful if you want want to extend objects after running findPaginate. Locally I have modified the model.find() to use .lean() and it works fine."}}