{"action":"created","issue":{"url":"https://api.github.com/repos/exercism/x-common/issues/158","labels_url":"https://api.github.com/repos/exercism/x-common/issues/158/labels{/name}","comments_url":"https://api.github.com/repos/exercism/x-common/issues/158/comments","events_url":"https://api.github.com/repos/exercism/x-common/issues/158/events","html_url":"https://github.com/exercism/x-common/pull/158","id":121126787,"number":158,"title":"simple-linked-list: update Ruby example to include null object pattern","user":{"login":"connorlay","id":6548350,"avatar_url":"https://avatars.githubusercontent.com/u/6548350?v=3","gravatar_id":"","url":"https://api.github.com/users/connorlay","html_url":"https://github.com/connorlay","followers_url":"https://api.github.com/users/connorlay/followers","following_url":"https://api.github.com/users/connorlay/following{/other_user}","gists_url":"https://api.github.com/users/connorlay/gists{/gist_id}","starred_url":"https://api.github.com/users/connorlay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/connorlay/subscriptions","organizations_url":"https://api.github.com/users/connorlay/orgs","repos_url":"https://api.github.com/users/connorlay/repos","events_url":"https://api.github.com/users/connorlay/events{/privacy}","received_events_url":"https://api.github.com/users/connorlay/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-12-08T23:41:31Z","updated_at":"2015-12-11T18:52:47Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/exercism/x-common/pulls/158","html_url":"https://github.com/exercism/x-common/pull/158","diff_url":"https://github.com/exercism/x-common/pull/158.diff","patch_url":"https://github.com/exercism/x-common/pull/158.patch"},"body":"In the simple-linked-list README we have the following example Ruby code:\r\n~~~ruby\r\nElement.to_a(nil) #=> []\r\nElement.from_a([]) #=> nil\r\nElement.reverse(nil) #=> nil\r\none = Element.new(1, nil)\r\none #=> <Element @datum=1, @next=nil>\r\none.datum #=> 1\r\none.next #=> nil\r\ntwo = Element.new(2, one)\r\ntwo #=> <Element @datum=2, @next=<Element @datum=1 @next=nil>>\r\nElement.to_a(two) #=> [2, 1]\r\nElement.reverse(two) #=> <Element @datum=1 @next=<Element @datum=2 @next=nil>>\r\nrange = Element.from_a(1..10)\r\nrange.datum #=> 1\r\nrange.next.next.next.next.next.next.next.next.next.next.datum #=> 10\r\n~~~\r\n\r\nHowever in `simple_linked_list_test.rb` we have the following test:\r\n~~~ruby\r\n  def test_empty_list_operations\r\n    skip\r\n    assert_equal [], Element.from_a([]).to_a\r\n    assert_equal [], Element.from_a([]).reverse.to_a\r\n  end\r\n~~~\r\n\r\nThe issue of the linked-list returning `nil` was addressed in [this commit](https://github.com/exercism/xruby/commit/fa6366e6f8a41da170205c0df6bd69fbf6d1e2ed), so I figured the Ruby code in the README should be updated to reflect that."},"comment":{"url":"https://api.github.com/repos/exercism/x-common/issues/comments/164016505","html_url":"https://github.com/exercism/x-common/pull/158#issuecomment-164016505","issue_url":"https://api.github.com/repos/exercism/x-common/issues/158","id":164016505,"user":{"login":"kytrinyx","id":276834,"avatar_url":"https://avatars.githubusercontent.com/u/276834?v=3","gravatar_id":"","url":"https://api.github.com/users/kytrinyx","html_url":"https://github.com/kytrinyx","followers_url":"https://api.github.com/users/kytrinyx/followers","following_url":"https://api.github.com/users/kytrinyx/following{/other_user}","gists_url":"https://api.github.com/users/kytrinyx/gists{/gist_id}","starred_url":"https://api.github.com/users/kytrinyx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kytrinyx/subscriptions","organizations_url":"https://api.github.com/users/kytrinyx/orgs","repos_url":"https://api.github.com/users/kytrinyx/repos","events_url":"https://api.github.com/users/kytrinyx/events{/privacy}","received_events_url":"https://api.github.com/users/kytrinyx/received_events","type":"User","site_admin":false},"created_at":"2015-12-11T18:52:47Z","updated_at":"2015-12-11T18:52:47Z","body":"Excellent! Thanks for taking the time to discuss and work through this."}}