{"action":"created","comment":{"url":"https://api.github.com/repos/u2i/confy/pulls/comments/76184764","id":76184764,"diff_hunk":"@@ -0,0 +1,31 @@\n+class NotificationController < ApplicationController\n+  before_action :fetch_conference_room\n+  before_action :validate_request\n+\n+  CHANNEL_ID_HEADER = 'X-Goog-Channel-ID'.freeze\n+\n+  def receive\n+    NotifyClientsJob.perform_later params[:conference_room_id]\n+    head :ok\n+  end\n+\n+  private\n+\n+  def validate_request\n+    head :bad_request unless valid_request?\n+  end\n+\n+  def valid_request?\n+    @conference_room && @conference_room.channel && @conference_room.channel.channel_id == channel_id","path":"app/controllers/notification_controller.rb","position":19,"original_position":19,"commit_id":"90518b70e64f8a48cb249eb4f99deb1227a482b1","original_commit_id":"cd47bca28c4fe93f7be0e3d8943ab3c3e6ea3235","user":{"login":"pbzymek","id":339719,"avatar_url":"https://avatars.githubusercontent.com/u/339719?v=3","gravatar_id":"","url":"https://api.github.com/users/pbzymek","html_url":"https://github.com/pbzymek","followers_url":"https://api.github.com/users/pbzymek/followers","following_url":"https://api.github.com/users/pbzymek/following{/other_user}","gists_url":"https://api.github.com/users/pbzymek/gists{/gist_id}","starred_url":"https://api.github.com/users/pbzymek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pbzymek/subscriptions","organizations_url":"https://api.github.com/users/pbzymek/orgs","repos_url":"https://api.github.com/users/pbzymek/repos","events_url":"https://api.github.com/users/pbzymek/events{/privacy}","received_events_url":"https://api.github.com/users/pbzymek/received_events","type":"User","site_admin":false},"body":"actually looking at the `fetch_conference_room` method there's no way `@conference_room` will be empty here","created_at":"2016-08-25T06:06:15Z","updated_at":"2016-08-25T06:06:15Z","html_url":"https://github.com/u2i/confy/pull/108#discussion_r76184764","pull_request_url":"https://api.github.com/repos/u2i/confy/pulls/108","_links":{"self":{"href":"https://api.github.com/repos/u2i/confy/pulls/comments/76184764"},"html":{"href":"https://github.com/u2i/confy/pull/108#discussion_r76184764"},"pull_request":{"href":"https://api.github.com/repos/u2i/confy/pulls/108"}}},"pull_request":{"url":"https://api.github.com/repos/u2i/confy/pulls/108","id":82499210,"html_url":"https://github.com/u2i/confy/pull/108","diff_url":"https://github.com/u2i/confy/pull/108.diff","patch_url":"https://github.com/u2i/confy/pull/108.patch","issue_url":"https://api.github.com/repos/u2i/confy/issues/108","number":108,"state":"open","locked":false,"title":"Websockets","user":{"login":"quirk0o","id":5123725,"avatar_url":"https://avatars.githubusercontent.com/u/5123725?v=3","gravatar_id":"","url":"https://api.github.com/users/quirk0o","html_url":"https://github.com/quirk0o","followers_url":"https://api.github.com/users/quirk0o/followers","following_url":"https://api.github.com/users/quirk0o/following{/other_user}","gists_url":"https://api.github.com/users/quirk0o/gists{/gist_id}","starred_url":"https://api.github.com/users/quirk0o/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quirk0o/subscriptions","organizations_url":"https://api.github.com/users/quirk0o/orgs","repos_url":"https://api.github.com/users/quirk0o/repos","events_url":"https://api.github.com/users/quirk0o/events{/privacy}","received_events_url":"https://api.github.com/users/quirk0o/received_events","type":"User","site_admin":false},"body":"@adamzima @s1mplex @pbzymek @lkudyba @mhib ","created_at":"2016-08-24T08:13:33Z","updated_at":"2016-08-25T06:06:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a6735076d6343780af9a2db652508d98839420af","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/u2i/confy/pulls/108/commits","review_comments_url":"https://api.github.com/repos/u2i/confy/pulls/108/comments","review_comment_url":"https://api.github.com/repos/u2i/confy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/u2i/confy/issues/108/comments","statuses_url":"https://api.github.com/repos/u2i/confy/statuses/90518b70e64f8a48cb249eb4f99deb1227a482b1","head":{"label":"u2i:websockets","ref":"websockets","sha":"90518b70e64f8a48cb249eb4f99deb1227a482b1","user":{"login":"u2i","id":856377,"avatar_url":"https://avatars.githubusercontent.com/u/856377?v=3","gravatar_id":"","url":"https://api.github.com/users/u2i","html_url":"https://github.com/u2i","followers_url":"https://api.github.com/users/u2i/followers","following_url":"https://api.github.com/users/u2i/following{/other_user}","gists_url":"https://api.github.com/users/u2i/gists{/gist_id}","starred_url":"https://api.github.com/users/u2i/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/u2i/subscriptions","organizations_url":"https://api.github.com/users/u2i/orgs","repos_url":"https://api.github.com/users/u2i/repos","events_url":"https://api.github.com/users/u2i/events{/privacy}","received_events_url":"https://api.github.com/users/u2i/received_events","type":"Organization","site_admin":false},"repo":{"id":62560182,"name":"confy","full_name":"u2i/confy","owner":{"login":"u2i","id":856377,"avatar_url":"https://avatars.githubusercontent.com/u/856377?v=3","gravatar_id":"","url":"https://api.github.com/users/u2i","html_url":"https://github.com/u2i","followers_url":"https://api.github.com/users/u2i/followers","following_url":"https://api.github.com/users/u2i/following{/other_user}","gists_url":"https://api.github.com/users/u2i/gists{/gist_id}","starred_url":"https://api.github.com/users/u2i/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/u2i/subscriptions","organizations_url":"https://api.github.com/users/u2i/orgs","repos_url":"https://api.github.com/users/u2i/repos","events_url":"https://api.github.com/users/u2i/events{/privacy}","received_events_url":"https://api.github.com/users/u2i/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/u2i/confy","description":null,"fork":false,"url":"https://api.github.com/repos/u2i/confy","forks_url":"https://api.github.com/repos/u2i/confy/forks","keys_url":"https://api.github.com/repos/u2i/confy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/u2i/confy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/u2i/confy/teams","hooks_url":"https://api.github.com/repos/u2i/confy/hooks","issue_events_url":"https://api.github.com/repos/u2i/confy/issues/events{/number}","events_url":"https://api.github.com/repos/u2i/confy/events","assignees_url":"https://api.github.com/repos/u2i/confy/assignees{/user}","branches_url":"https://api.github.com/repos/u2i/confy/branches{/branch}","tags_url":"https://api.github.com/repos/u2i/confy/tags","blobs_url":"https://api.github.com/repos/u2i/confy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/u2i/confy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/u2i/confy/git/refs{/sha}","trees_url":"https://api.github.com/repos/u2i/confy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/u2i/confy/statuses/{sha}","languages_url":"https://api.github.com/repos/u2i/confy/languages","stargazers_url":"https://api.github.com/repos/u2i/confy/stargazers","contributors_url":"https://api.github.com/repos/u2i/confy/contributors","subscribers_url":"https://api.github.com/repos/u2i/confy/subscribers","subscription_url":"https://api.github.com/repos/u2i/confy/subscription","commits_url":"https://api.github.com/repos/u2i/confy/commits{/sha}","git_commits_url":"https://api.github.com/repos/u2i/confy/git/commits{/sha}","comments_url":"https://api.github.com/repos/u2i/confy/comments{/number}","issue_comment_url":"https://api.github.com/repos/u2i/confy/issues/comments{/number}","contents_url":"https://api.github.com/repos/u2i/confy/contents/{+path}","compare_url":"https://api.github.com/repos/u2i/confy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/u2i/confy/merges","archive_url":"https://api.github.com/repos/u2i/confy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/u2i/confy/downloads","issues_url":"https://api.github.com/repos/u2i/confy/issues{/number}","pulls_url":"https://api.github.com/repos/u2i/confy/pulls{/number}","milestones_url":"https://api.github.com/repos/u2i/confy/milestones{/number}","notifications_url":"https://api.github.com/repos/u2i/confy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/u2i/confy/labels{/name}","releases_url":"https://api.github.com/repos/u2i/confy/releases{/id}","deployments_url":"https://api.github.com/repos/u2i/confy/deployments","created_at":"2016-07-04T12:23:19Z","updated_at":"2016-08-24T11:22:37Z","pushed_at":"2016-08-24T15:16:38Z","git_url":"git://github.com/u2i/confy.git","ssh_url":"git@github.com:u2i/confy.git","clone_url":"https://github.com/u2i/confy.git","svn_url":"https://github.com/u2i/confy","homepage":null,"size":842,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"develop"}},"base":{"label":"u2i:develop","ref":"develop","sha":"beec8fba1d727b4d3cde82bb4e7aa9e34cdb9b0b","user":{"login":"u2i","id":856377,"avatar_url":"https://avatars.githubusercontent.com/u/856377?v=3","gravatar_id":"","url":"https://api.github.com/users/u2i","html_url":"https://github.com/u2i","followers_url":"https://api.github.com/users/u2i/followers","following_url":"https://api.github.com/users/u2i/following{/other_user}","gists_url":"https://api.github.com/users/u2i/gists{/gist_id}","starred_url":"https://api.github.com/users/u2i/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/u2i/subscriptions","organizations_url":"https://api.github.com/users/u2i/orgs","repos_url":"https://api.github.com/users/u2i/repos","events_url":"https://api.github.com/users/u2i/events{/privacy}","received_events_url":"https://api.github.com/users/u2i/received_events","type":"Organization","site_admin":false},"repo":{"id":62560182,"name":"confy","full_name":"u2i/confy","owner":{"login":"u2i","id":856377,"avatar_url":"https://avatars.githubusercontent.com/u/856377?v=3","gravatar_id":"","url":"https://api.github.com/users/u2i","html_url":"https://github.com/u2i","followers_url":"https://api.github.com/users/u2i/followers","following_url":"https://api.github.com/users/u2i/following{/other_user}","gists_url":"https://api.github.com/users/u2i/gists{/gist_id}","starred_url":"https://api.github.com/users/u2i/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/u2i/subscriptions","organizations_url":"https://api.github.com/users/u2i/orgs","repos_url":"https://api.github.com/users/u2i/repos","events_url":"https://api.github.com/users/u2i/events{/privacy}","received_events_url":"https://api.github.com/users/u2i/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/u2i/confy","description":null,"fork":false,"url":"https://api.github.com/repos/u2i/confy","forks_url":"https://api.github.com/repos/u2i/confy/forks","keys_url":"https://api.github.com/repos/u2i/confy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/u2i/confy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/u2i/confy/teams","hooks_url":"https://api.github.com/repos/u2i/confy/hooks","issue_events_url":"https://api.github.com/repos/u2i/confy/issues/events{/number}","events_url":"https://api.github.com/repos/u2i/confy/events","assignees_url":"https://api.github.com/repos/u2i/confy/assignees{/user}","branches_url":"https://api.github.com/repos/u2i/confy/branches{/branch}","tags_url":"https://api.github.com/repos/u2i/confy/tags","blobs_url":"https://api.github.com/repos/u2i/confy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/u2i/confy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/u2i/confy/git/refs{/sha}","trees_url":"https://api.github.com/repos/u2i/confy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/u2i/confy/statuses/{sha}","languages_url":"https://api.github.com/repos/u2i/confy/languages","stargazers_url":"https://api.github.com/repos/u2i/confy/stargazers","contributors_url":"https://api.github.com/repos/u2i/confy/contributors","subscribers_url":"https://api.github.com/repos/u2i/confy/subscribers","subscription_url":"https://api.github.com/repos/u2i/confy/subscription","commits_url":"https://api.github.com/repos/u2i/confy/commits{/sha}","git_commits_url":"https://api.github.com/repos/u2i/confy/git/commits{/sha}","comments_url":"https://api.github.com/repos/u2i/confy/comments{/number}","issue_comment_url":"https://api.github.com/repos/u2i/confy/issues/comments{/number}","contents_url":"https://api.github.com/repos/u2i/confy/contents/{+path}","compare_url":"https://api.github.com/repos/u2i/confy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/u2i/confy/merges","archive_url":"https://api.github.com/repos/u2i/confy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/u2i/confy/downloads","issues_url":"https://api.github.com/repos/u2i/confy/issues{/number}","pulls_url":"https://api.github.com/repos/u2i/confy/pulls{/number}","milestones_url":"https://api.github.com/repos/u2i/confy/milestones{/number}","notifications_url":"https://api.github.com/repos/u2i/confy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/u2i/confy/labels{/name}","releases_url":"https://api.github.com/repos/u2i/confy/releases{/id}","deployments_url":"https://api.github.com/repos/u2i/confy/deployments","created_at":"2016-07-04T12:23:19Z","updated_at":"2016-08-24T11:22:37Z","pushed_at":"2016-08-24T15:16:38Z","git_url":"git://github.com/u2i/confy.git","ssh_url":"git@github.com:u2i/confy.git","clone_url":"https://github.com/u2i/confy.git","svn_url":"https://github.com/u2i/confy","homepage":null,"size":842,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/u2i/confy/pulls/108"},"html":{"href":"https://github.com/u2i/confy/pull/108"},"issue":{"href":"https://api.github.com/repos/u2i/confy/issues/108"},"comments":{"href":"https://api.github.com/repos/u2i/confy/issues/108/comments"},"review_comments":{"href":"https://api.github.com/repos/u2i/confy/pulls/108/comments"},"review_comment":{"href":"https://api.github.com/repos/u2i/confy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/u2i/confy/pulls/108/commits"},"statuses":{"href":"https://api.github.com/repos/u2i/confy/statuses/90518b70e64f8a48cb249eb4f99deb1227a482b1"}}}}
{"actor":{"display_login":"pbzymek"}}