{"action":"created","issue":{"url":"https://api.github.com/repos/evilstreak/curryable/issues/3","labels_url":"https://api.github.com/repos/evilstreak/curryable/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/evilstreak/curryable/issues/3/comments","events_url":"https://api.github.com/repos/evilstreak/curryable/issues/3/events","html_url":"https://github.com/evilstreak/curryable/pull/3","id":107395772,"number":3,"title":"Remove global variables in favor of closures","user":{"login":"bestie","id":145723,"avatar_url":"https://avatars.githubusercontent.com/u/145723?v=3","gravatar_id":"","url":"https://api.github.com/users/bestie","html_url":"https://github.com/bestie","followers_url":"https://api.github.com/users/bestie/followers","following_url":"https://api.github.com/users/bestie/following{/other_user}","gists_url":"https://api.github.com/users/bestie/gists{/gist_id}","starred_url":"https://api.github.com/users/bestie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bestie/subscriptions","organizations_url":"https://api.github.com/users/bestie/orgs","repos_url":"https://api.github.com/users/bestie/repos","events_url":"https://api.github.com/users/bestie/events{/privacy}","received_events_url":"https://api.github.com/users/bestie/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-20T14:38:44Z","updated_at":"2015-09-22T07:59:29Z","closed_at":"2015-09-22T07:57:18Z","pull_request":{"url":"https://api.github.com/repos/evilstreak/curryable/pulls/3","html_url":"https://github.com/evilstreak/curryable/pull/3","diff_url":"https://github.com/evilstreak/curryable/pull/3.diff","patch_url":"https://github.com/evilstreak/curryable/pull/3.patch"},"body":"In order for our `command_spy` to be in scope in both our dummy classes\r\nand our tests we thought the only easy way would be to make it global.\r\nRSpec however has the virtue of making heavy use of block and closures.\r\nThis change attempts to leverage Ruby's lexical scoping to fight the war\r\nagainst global vars.\r\n\r\nDollar signs are gross anyway is this PHP or something?\r\n\r\nCheck these out:\r\n* http://myronmars.to/n/dev-blog/2012/10/using-closures-to-avoid-leaking-state\r\n* https://github.com/bestie/objective-ruby-style-guide"},"comment":{"url":"https://api.github.com/repos/evilstreak/curryable/issues/comments/142206776","html_url":"https://github.com/evilstreak/curryable/pull/3#issuecomment-142206776","issue_url":"https://api.github.com/repos/evilstreak/curryable/issues/3","id":142206776,"user":{"login":"evilstreak","id":74812,"avatar_url":"https://avatars.githubusercontent.com/u/74812?v=3","gravatar_id":"","url":"https://api.github.com/users/evilstreak","html_url":"https://github.com/evilstreak","followers_url":"https://api.github.com/users/evilstreak/followers","following_url":"https://api.github.com/users/evilstreak/following{/other_user}","gists_url":"https://api.github.com/users/evilstreak/gists{/gist_id}","starred_url":"https://api.github.com/users/evilstreak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evilstreak/subscriptions","organizations_url":"https://api.github.com/users/evilstreak/orgs","repos_url":"https://api.github.com/users/evilstreak/repos","events_url":"https://api.github.com/users/evilstreak/events{/privacy}","received_events_url":"https://api.github.com/users/evilstreak/received_events","type":"User","site_admin":false},"created_at":"2015-09-22T07:59:29Z","updated_at":"2015-09-22T07:59:29Z","body":":no_entry_sign::heavy_dollar_sign::+1:"}}