{"action":"created","comment":{"url":"https://api.github.com/repos/guardian/membership-frontend/pulls/comments/23997631","id":23997631,"diff_hunk":"@@ -99,6 +99,14 @@ object RichEvent {\n \n     private val widths = image.fold(List.empty[Int])(_.assets.map(_.dimensions.width))\n \n+    val pastImageOpt = {\n+      val elementOpt = content.flatMap(c => c.elements.flatMap(_.find(_.relation == \"main\")))\n+      elementOpt.flatMap{ element =>\n+        val assets = element.assets\n+        assets.find(a => a.typeData.get(\"width\") == Some(\"460\"))\n+      }","path":"frontend/app/model/RichEvent.scala","position":null,"original_position":70,"commit_id":"5f24e3ef3e80967c73b614f14972d0a308fe07b0","original_commit_id":"572478c3c5a73bb64807adcbf334f3e1d180ecb8","user":{"login":"jennysivapalan","id":944375,"avatar_url":"https://avatars.githubusercontent.com/u/944375?v=3","gravatar_id":"","url":"https://api.github.com/users/jennysivapalan","html_url":"https://github.com/jennysivapalan","followers_url":"https://api.github.com/users/jennysivapalan/followers","following_url":"https://api.github.com/users/jennysivapalan/following{/other_user}","gists_url":"https://api.github.com/users/jennysivapalan/gists{/gist_id}","starred_url":"https://api.github.com/users/jennysivapalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jennysivapalan/subscriptions","organizations_url":"https://api.github.com/users/jennysivapalan/orgs","repos_url":"https://api.github.com/users/jennysivapalan/repos","events_url":"https://api.github.com/users/jennysivapalan/events{/privacy}","received_events_url":"https://api.github.com/users/jennysivapalan/received_events","type":"User","site_admin":false},"body":"done!","created_at":"2015-02-03T11:28:50Z","updated_at":"2015-02-03T11:28:50Z","html_url":"https://github.com/guardian/membership-frontend/pull/139#discussion_r23997631","pull_request_url":"https://api.github.com/repos/guardian/membership-frontend/pulls/139","_links":{"self":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/comments/23997631"},"html":{"href":"https://github.com/guardian/membership-frontend/pull/139#discussion_r23997631"},"pull_request":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/139"}}},"pull_request":{"url":"https://api.github.com/repos/guardian/membership-frontend/pulls/139","id":28353901,"html_url":"https://github.com/guardian/membership-frontend/pull/139","diff_url":"https://github.com/guardian/membership-frontend/pull/139.diff","patch_url":"https://github.com/guardian/membership-frontend/pull/139.patch","issue_url":"https://api.github.com/repos/guardian/membership-frontend/issues/139","number":139,"state":"open","locked":false,"title":"Adds a panel with link to Guardian article for past event","user":{"login":"jennysivapalan","id":944375,"avatar_url":"https://avatars.githubusercontent.com/u/944375?v=3","gravatar_id":"","url":"https://api.github.com/users/jennysivapalan","html_url":"https://github.com/jennysivapalan","followers_url":"https://api.github.com/users/jennysivapalan/followers","following_url":"https://api.github.com/users/jennysivapalan/following{/other_user}","gists_url":"https://api.github.com/users/jennysivapalan/gists{/gist_id}","starred_url":"https://api.github.com/users/jennysivapalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jennysivapalan/subscriptions","organizations_url":"https://api.github.com/users/jennysivapalan/orgs","repos_url":"https://api.github.com/users/jennysivapalan/repos","events_url":"https://api.github.com/users/jennysivapalan/events{/privacy}","received_events_url":"https://api.github.com/users/jennysivapalan/received_events","type":"User","site_admin":false},"body":"Ta da :tada: \r\n![screen shot 2015-01-30 at 11 07 58](https://cloud.githubusercontent.com/assets/944375/5974806/63390dac-a870-11e4-8d66-d10179aee885.png)\r\n\r\n* Replaced MasterclassDataService with a GuardianContentService. This has two tasks, one is the existing call for masterclass content. A new call to get content based on eventbrite reference has been added.\r\n* I'd like to do some refactoring around GuEvent and MasterclassEvent as it's getting a bit bloated. I think we can get rid of the MasterclassData class.  I'll do this a separate PR though.\r\n* As discussed I've removed the ticket info panel for past events.","created_at":"2015-01-30T11:12:51Z","updated_at":"2015-02-03T11:28:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"44aa9f838c9c9317c41a397d660f4d4ef3565288","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/guardian/membership-frontend/pulls/139/commits","review_comments_url":"https://api.github.com/repos/guardian/membership-frontend/pulls/139/comments","review_comment_url":"https://api.github.com/repos/guardian/membership-frontend/pulls/comments/{number}","comments_url":"https://api.github.com/repos/guardian/membership-frontend/issues/139/comments","statuses_url":"https://api.github.com/repos/guardian/membership-frontend/statuses/5f24e3ef3e80967c73b614f14972d0a308fe07b0","head":{"label":"guardian:link-event-to-gu","ref":"link-event-to-gu","sha":"5f24e3ef3e80967c73b614f14972d0a308fe07b0","user":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"repo":{"id":28401521,"name":"membership-frontend","full_name":"guardian/membership-frontend","owner":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/guardian/membership-frontend","description":"Bringing the Guardian to life through live events and meet-ups","fork":false,"url":"https://api.github.com/repos/guardian/membership-frontend","forks_url":"https://api.github.com/repos/guardian/membership-frontend/forks","keys_url":"https://api.github.com/repos/guardian/membership-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guardian/membership-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guardian/membership-frontend/teams","hooks_url":"https://api.github.com/repos/guardian/membership-frontend/hooks","issue_events_url":"https://api.github.com/repos/guardian/membership-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/guardian/membership-frontend/events","assignees_url":"https://api.github.com/repos/guardian/membership-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/guardian/membership-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/guardian/membership-frontend/tags","blobs_url":"https://api.github.com/repos/guardian/membership-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guardian/membership-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guardian/membership-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/guardian/membership-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guardian/membership-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/guardian/membership-frontend/languages","stargazers_url":"https://api.github.com/repos/guardian/membership-frontend/stargazers","contributors_url":"https://api.github.com/repos/guardian/membership-frontend/contributors","subscribers_url":"https://api.github.com/repos/guardian/membership-frontend/subscribers","subscription_url":"https://api.github.com/repos/guardian/membership-frontend/subscription","commits_url":"https://api.github.com/repos/guardian/membership-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/guardian/membership-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/guardian/membership-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/guardian/membership-frontend/issues/comments/{number}","contents_url":"https://api.github.com/repos/guardian/membership-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/guardian/membership-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guardian/membership-frontend/merges","archive_url":"https://api.github.com/repos/guardian/membership-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guardian/membership-frontend/downloads","issues_url":"https://api.github.com/repos/guardian/membership-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/guardian/membership-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/guardian/membership-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/guardian/membership-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guardian/membership-frontend/labels{/name}","releases_url":"https://api.github.com/repos/guardian/membership-frontend/releases{/id}","created_at":"2014-12-23T14:14:38Z","updated_at":"2015-02-03T10:45:53Z","pushed_at":"2015-02-03T11:28:40Z","git_url":"git://github.com/guardian/membership-frontend.git","ssh_url":"git@github.com:guardian/membership-frontend.git","clone_url":"https://github.com/guardian/membership-frontend.git","svn_url":"https://github.com/guardian/membership-frontend","homepage":"https://membership.theguardian.com/","size":23779,"stargazers_count":4,"watchers_count":4,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":4,"default_branch":"master"}},"base":{"label":"guardian:master","ref":"master","sha":"2d5ac0b30520d32610b5e405c94adf97ebc38416","user":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"repo":{"id":28401521,"name":"membership-frontend","full_name":"guardian/membership-frontend","owner":{"login":"guardian","id":164318,"avatar_url":"https://avatars.githubusercontent.com/u/164318?v=3","gravatar_id":"","url":"https://api.github.com/users/guardian","html_url":"https://github.com/guardian","followers_url":"https://api.github.com/users/guardian/followers","following_url":"https://api.github.com/users/guardian/following{/other_user}","gists_url":"https://api.github.com/users/guardian/gists{/gist_id}","starred_url":"https://api.github.com/users/guardian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guardian/subscriptions","organizations_url":"https://api.github.com/users/guardian/orgs","repos_url":"https://api.github.com/users/guardian/repos","events_url":"https://api.github.com/users/guardian/events{/privacy}","received_events_url":"https://api.github.com/users/guardian/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/guardian/membership-frontend","description":"Bringing the Guardian to life through live events and meet-ups","fork":false,"url":"https://api.github.com/repos/guardian/membership-frontend","forks_url":"https://api.github.com/repos/guardian/membership-frontend/forks","keys_url":"https://api.github.com/repos/guardian/membership-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/guardian/membership-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/guardian/membership-frontend/teams","hooks_url":"https://api.github.com/repos/guardian/membership-frontend/hooks","issue_events_url":"https://api.github.com/repos/guardian/membership-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/guardian/membership-frontend/events","assignees_url":"https://api.github.com/repos/guardian/membership-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/guardian/membership-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/guardian/membership-frontend/tags","blobs_url":"https://api.github.com/repos/guardian/membership-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/guardian/membership-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/guardian/membership-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/guardian/membership-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/guardian/membership-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/guardian/membership-frontend/languages","stargazers_url":"https://api.github.com/repos/guardian/membership-frontend/stargazers","contributors_url":"https://api.github.com/repos/guardian/membership-frontend/contributors","subscribers_url":"https://api.github.com/repos/guardian/membership-frontend/subscribers","subscription_url":"https://api.github.com/repos/guardian/membership-frontend/subscription","commits_url":"https://api.github.com/repos/guardian/membership-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/guardian/membership-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/guardian/membership-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/guardian/membership-frontend/issues/comments/{number}","contents_url":"https://api.github.com/repos/guardian/membership-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/guardian/membership-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/guardian/membership-frontend/merges","archive_url":"https://api.github.com/repos/guardian/membership-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/guardian/membership-frontend/downloads","issues_url":"https://api.github.com/repos/guardian/membership-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/guardian/membership-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/guardian/membership-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/guardian/membership-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/guardian/membership-frontend/labels{/name}","releases_url":"https://api.github.com/repos/guardian/membership-frontend/releases{/id}","created_at":"2014-12-23T14:14:38Z","updated_at":"2015-02-03T10:45:53Z","pushed_at":"2015-02-03T11:28:40Z","git_url":"git://github.com/guardian/membership-frontend.git","ssh_url":"git@github.com:guardian/membership-frontend.git","clone_url":"https://github.com/guardian/membership-frontend.git","svn_url":"https://github.com/guardian/membership-frontend","homepage":"https://membership.theguardian.com/","size":23779,"stargazers_count":4,"watchers_count":4,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/139"},"html":{"href":"https://github.com/guardian/membership-frontend/pull/139"},"issue":{"href":"https://api.github.com/repos/guardian/membership-frontend/issues/139"},"comments":{"href":"https://api.github.com/repos/guardian/membership-frontend/issues/139/comments"},"review_comments":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/139/comments"},"review_comment":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/guardian/membership-frontend/pulls/139/commits"},"statuses":{"href":"https://api.github.com/repos/guardian/membership-frontend/statuses/5f24e3ef3e80967c73b614f14972d0a308fe07b0"}}}}