{"action":"created","issue":{"url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/5","repository_url":"https://api.github.com/repos/CodementorIO/rest-firebase","labels_url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/5/comments","events_url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/5/events","html_url":"https://github.com/CodementorIO/rest-firebase/issues/5","id":105508541,"number":5,"title":"Something's wrong with nil","user":{"login":"wyattisimo","id":625546,"avatar_url":"https://avatars.githubusercontent.com/u/625546?v=3","gravatar_id":"","url":"https://api.github.com/users/wyattisimo","html_url":"https://github.com/wyattisimo","followers_url":"https://api.github.com/users/wyattisimo/followers","following_url":"https://api.github.com/users/wyattisimo/following{/other_user}","gists_url":"https://api.github.com/users/wyattisimo/gists{/gist_id}","starred_url":"https://api.github.com/users/wyattisimo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wyattisimo/subscriptions","organizations_url":"https://api.github.com/users/wyattisimo/orgs","repos_url":"https://api.github.com/users/wyattisimo/repos","events_url":"https://api.github.com/users/wyattisimo/events{/privacy}","received_events_url":"https://api.github.com/users/wyattisimo/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2015-09-09T02:56:37Z","updated_at":"2016-08-24T08:10:51Z","closed_at":"2016-08-24T08:10:51Z","body":"Given a hash at `/path/to/something` and no value at `/path/to/nothing`, consider the following:\r\n\r\n```ruby\r\nfirebase  = RestFirebase.new(secret: ENV['FIREBASE_SECRET'], d: { consumer: ENV['FIREBASE_CONSUMER_AUTH_VALUE'] })\r\nsomething = firebase.get(\"#{ENV['FIREBASE_URL']}/path/to/something\")\r\nnothing   = firebase.get(\"#{ENV['FIREBASE_URL']}/path/to/nothing\")\r\n```\r\n\r\nThen:\r\n\r\n```ruby\r\nsomething.class\r\n# => Hash\r\nnothing.class\r\n# => NilClass\r\n\r\nsomething.nil?\r\n# => false\r\nnothing.nil?\r\n# => true\r\n\r\nsomething == nil\r\n# => false\r\nnothing == nil\r\n# => false\r\n\r\nsomething === nil\r\n# => false\r\nnothing === nil\r\n# => true\r\n```\r\n\r\nIt appears that `nothing` is appropriately `nil` unless you try the comparison `nothing == nil`, which erroneously returns `false`.\r\n\r\nWhy is this the case? Is `NilClass#==` being overridden somewhere?"},"comment":{"url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/comments/241989226","html_url":"https://github.com/CodementorIO/rest-firebase/issues/5#issuecomment-241989226","issue_url":"https://api.github.com/repos/CodementorIO/rest-firebase/issues/5","id":241989226,"user":{"login":"godfat","id":10416,"avatar_url":"https://avatars.githubusercontent.com/u/10416?v=3","gravatar_id":"","url":"https://api.github.com/users/godfat","html_url":"https://github.com/godfat","followers_url":"https://api.github.com/users/godfat/followers","following_url":"https://api.github.com/users/godfat/following{/other_user}","gists_url":"https://api.github.com/users/godfat/gists{/gist_id}","starred_url":"https://api.github.com/users/godfat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/godfat/subscriptions","organizations_url":"https://api.github.com/users/godfat/orgs","repos_url":"https://api.github.com/users/godfat/repos","events_url":"https://api.github.com/users/godfat/events{/privacy}","received_events_url":"https://api.github.com/users/godfat/received_events","type":"User","site_admin":false},"created_at":"2016-08-24T08:10:51Z","updated_at":"2016-08-24T08:10:51Z","body":"Let's move the discussion over to https://github.com/godfat/rest-core/issues/9"}}
{"actor":{"display_login":"godfat"}}