{"action":"created","issue":{"url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/22","repository_url":"https://api.github.com/repos/siegesmund/SwiftDDP","labels_url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/22/labels{/name}","comments_url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/22/comments","events_url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/22/events","html_url":"https://github.com/siegesmund/SwiftDDP/issues/22","id":142215698,"number":22,"title":"Getting the current user object","user":{"login":"Sef1995","id":3214653,"avatar_url":"https://avatars.githubusercontent.com/u/3214653?v=3","gravatar_id":"","url":"https://api.github.com/users/Sef1995","html_url":"https://github.com/Sef1995","followers_url":"https://api.github.com/users/Sef1995/followers","following_url":"https://api.github.com/users/Sef1995/following{/other_user}","gists_url":"https://api.github.com/users/Sef1995/gists{/gist_id}","starred_url":"https://api.github.com/users/Sef1995/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sef1995/subscriptions","organizations_url":"https://api.github.com/users/Sef1995/orgs","repos_url":"https://api.github.com/users/Sef1995/repos","events_url":"https://api.github.com/users/Sef1995/events{/privacy}","received_events_url":"https://api.github.com/users/Sef1995/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2016-03-20T22:35:18Z","updated_at":"2016-03-21T13:21:53Z","closed_at":null,"body":"Hi there love the library. However I'm having trouble getting the current user object after being logged in. I'm curious about the fact if I need to manually subscribe after logging in or will it do it automatically?\r\nAlso is there any example code of instructions I might've missed that implement the basics.\r\n\r\nAlso I'd like to add that I'm using Meteor accounts and I'm wondering how nested properties like the \"profile\" property will look like class wise.\r\n\r\nAny help at all would be very welcome! Excellent job so far!"},"comment":{"url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/comments/199273536","html_url":"https://github.com/siegesmund/SwiftDDP/issues/22#issuecomment-199273536","issue_url":"https://api.github.com/repos/siegesmund/SwiftDDP/issues/22","id":199273536,"user":{"login":"Sef1995","id":3214653,"avatar_url":"https://avatars.githubusercontent.com/u/3214653?v=3","gravatar_id":"","url":"https://api.github.com/users/Sef1995","html_url":"https://github.com/Sef1995","followers_url":"https://api.github.com/users/Sef1995/followers","following_url":"https://api.github.com/users/Sef1995/following{/other_user}","gists_url":"https://api.github.com/users/Sef1995/gists{/gist_id}","starred_url":"https://api.github.com/users/Sef1995/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sef1995/subscriptions","organizations_url":"https://api.github.com/users/Sef1995/orgs","repos_url":"https://api.github.com/users/Sef1995/repos","events_url":"https://api.github.com/users/Sef1995/events{/privacy}","received_events_url":"https://api.github.com/users/Sef1995/received_events","type":"User","site_admin":false},"created_at":"2016-03-21T13:21:53Z","updated_at":"2016-03-21T13:21:53Z","body":"@siegesmund Thanks for your reply. I've changed my code in the DashboardViewController to:\r\n```\r\nclass DashboardViewController: UIViewController {\r\n    \r\n    let MH : Server = Server.sharedInstance\r\n\r\n    override func viewDidLoad() {\r\n        super.viewDidLoad()\r\n\r\n        self.title = \"Dashboard\"\r\n        \r\n        let currentUser = MH.currentUser.findOne(Meteor.client.userId()!)\r\n\r\n        print(currentUser!.valueForKey(\"profile\"))\r\n    }\r\n    \r\n    override func didReceiveMemoryWarning() {\r\n        super.didReceiveMemoryWarning()\r\n        // Dispose of any resources that can be recreated.\r\n    }\r\n}\r\n```\r\n\r\nWhen I run the app it crashes with this fatal error: \r\n\r\n> unexpectedly found nil while unwrapping an Optional value"}}