GitHub PullRequestReviewCommentEvent at 2014-01-06 02:13:33
Repository: active_shipping
Actor: levity
Payload: {"comment":{"url":"https://api.github.com/repos/Shopify/active_shipping/pulls/comments/8658138","id":8658138,"diff_hunk":"@@ -380,10 +380,12 @@ def parse_tracking_response(response, options={})\n             # This adds an origin event to the shipment activity in such cases.\n             if origin && !(shipment_events.count == 1 && status == :delivered)\n               first_event = shipment_events[0]\n-              same_country = origin.country_code(:alpha2) == first_event.location.country_code(:alpha2)\n-              same_or_blank_city = first_event.location.city.blank? or first_event.location.city == origin.city\n+              if first_event.location\n+                same_country = origin.country_code(:alpha2) == first_event.location.country_code(:alpha2)\n+                same_or_blank_city = first_event.location.city.blank? or first_event.location.city == origin.city\n+              end\n               origin_event = ShipmentEvent.new(first_event.name, first_event.time, origin)\n-              if same_country and same_or_blank_city\n+              if first_event.location and same_country and same_or_blank_city","path":"lib/active_shipping/shipping/carriers/ups.rb","position":12,"original_position":12,"commit_id":"5197f350879335b08908570b3e10e7f5826180dc","original_commit_id":"5197f350879335b08908570b3e10e7f5826180dc","user":{"login":"levity","id":193667,"avatar_url":"https://gravatar.com/avatar/51ac8ca0bfc70f0bca64c3bec0cb473c?d=https%3A%2F%2Fidenticons.github.com%2F787907eaa93e7a5f65334b9cfe537e9e.png&r=x","gravatar_id":"51ac8ca0bfc70f0bca64c3bec0cb473c","url":"https://api.github.com/users/levity","html_url":"https://github.com/levity","followers_url":"https://api.github.com/users/levity/followers","following_url":"https://api.github.com/users/levity/following{/other_user}","gists_url":"https://api.github.com/users/levity/gists{/gist_id}","starred_url":"https://api.github.com/users/levity/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/levity/subscriptions","organizations_url":"https://api.github.com/users/levity/orgs","repos_url":"https://api.github.com/users/levity/repos","events_url":"https://api.github.com/users/levity/events{/privacy}","received_events_url":"https://api.github.com/users/levity/received_events","type":"User","site_admin":false},"body":"That makes sense to me. You had better take care of it; I'm unfamiliar with the organization of the code and just wanted to make the smallest change necessary to resolve some production issues I was seeing. Thanks for helping maintain this gem!","created_at":"2014-01-06T02:13:33Z","updated_at":"2014-01-06T02:13:33Z","html_url":"https://github.com/Shopify/active_shipping/pull/128#discussion_r8658138","pull_request_url":"https://api.github.com/repos/Shopify/active_shipping/pulls/128","_links":{"self":{"href":"https://api.github.com/repos/Shopify/active_shipping/pulls/comments/8658138"},"html":{"href":"https://github.com/Shopify/active_shipping/pull/128#discussion_r8658138"},"pull_request":{"href":"https://api.github.com/repos/Shopify/active_shipping/pulls/128"}}}}