{"action":"closed","issue":{"url":"https://api.github.com/repos/hamstergem/hamster/issues/183","labels_url":"https://api.github.com/repos/hamstergem/hamster/issues/183/labels{/name}","comments_url":"https://api.github.com/repos/hamstergem/hamster/issues/183/comments","events_url":"https://api.github.com/repos/hamstergem/hamster/issues/183/events","html_url":"https://github.com/hamstergem/hamster/issues/183","id":101188420,"number":183,"title":"Vector#assoc should return nil for malformed vectors.","user":{"login":"xaviershay","id":1714,"avatar_url":"https://avatars.githubusercontent.com/u/1714?v=3","gravatar_id":"","url":"https://api.github.com/users/xaviershay","html_url":"https://github.com/xaviershay","followers_url":"https://api.github.com/users/xaviershay/followers","following_url":"https://api.github.com/users/xaviershay/following{/other_user}","gists_url":"https://api.github.com/users/xaviershay/gists{/gist_id}","starred_url":"https://api.github.com/users/xaviershay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaviershay/subscriptions","organizations_url":"https://api.github.com/users/xaviershay/orgs","repos_url":"https://api.github.com/users/xaviershay/repos","events_url":"https://api.github.com/users/xaviershay/events{/privacy}","received_events_url":"https://api.github.com/users/xaviershay/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-08-15T16:35:51Z","updated_at":"2015-09-14T13:49:08Z","closed_at":"2015-09-14T13:49:08Z","body":"```\r\nirb(main):027:0> [[1, 2], nil].assoc(3)\r\n=> nil\r\nirb(main):028:0> Hamster.vector([1, 2], nil).assoc(3)\r\nNoMethodError: undefined method `[]' for nil:NilClass\r\n\tfrom /Users/xavier/.gem/ruby/2.2.2/gems/hamster-1.0.0/lib/hamster/vector.rb:1143:in `block in assoc'\r\n\tfrom /Users/xavier/.gem/ruby/2.2.2/gems/hamster-1.0.0/lib/hamster/vector.rb:1205:in `each'\r\n\tfrom /Users/xavier/.gem/ruby/2.2.2/gems/hamster-1.0.0/lib/hamster/vector.rb:1205:in `traverse_depth_first'\r\n\tfrom /Users/xavier/.gem/ruby/2.2.2/gems/hamster-1.0.0/lib/hamster/vector.rb:405:in `each'\r\n\tfrom /Users/xavier/.gem/ruby/2.2.2/gems/hamster-1.0.0/lib/hamster/vector.rb:1143:in `assoc'\r\n\tfrom (irb):28\r\n\tfrom /Users/xavier/.rubies/cruby-2.2.2/bin/irb:11:in `<main>'\r\n```\r\n\r\nI plan to fix this, just filing here so I don't forget."}}