{"action":"created","comment":{"url":"https://api.github.com/repos/alteregoizm/qna2/pulls/comments/81501122","pull_request_review_id":2476279,"id":81501122,"diff_hunk":"@@ -4,7 +4,19 @@ class Question < ActiveRecord::Base\n   include Commentable\n \n   has_many :answers, dependent: :destroy\n+  has_many :subscriptions, dependent: :destroy\n   belongs_to :user\n \n   validates :title, :body, :user_id,  presence: true\n+\n+  after_create :author_subscribe\n+\n+  # scope :created_for_day, -> { where(created_at: 1.day.ago..Time.zone.now) }\n+  scope :created_for_day, -> { where(created_at: Time.current.yesterday.all_day) }","path":"app/models/question.rb","position":12,"original_position":12,"commit_id":"d027d42a5a8c4f234acf7af133e82453ff19d795","original_commit_id":"d027d42a5a8c4f234acf7af133e82453ff19d795","user":{"login":"vkurennov","id":968537,"avatar_url":"https://avatars.githubusercontent.com/u/968537?v=3","gravatar_id":"","url":"https://api.github.com/users/vkurennov","html_url":"https://github.com/vkurennov","followers_url":"https://api.github.com/users/vkurennov/followers","following_url":"https://api.github.com/users/vkurennov/following{/other_user}","gists_url":"https://api.github.com/users/vkurennov/gists{/gist_id}","starred_url":"https://api.github.com/users/vkurennov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vkurennov/subscriptions","organizations_url":"https://api.github.com/users/vkurennov/orgs","repos_url":"https://api.github.com/users/vkurennov/repos","events_url":"https://api.github.com/users/vkurennov/events{/privacy}","received_events_url":"https://api.github.com/users/vkurennov/received_events","type":"User","site_admin":false},"body":"Вот же скуоп, почему его не используешь в DailyDigestJob?","created_at":"2016-10-03T07:27:56Z","updated_at":"2016-10-03T07:28:17Z","html_url":"https://github.com/alteregoizm/qna2/pull/15#discussion_r81501122","pull_request_url":"https://api.github.com/repos/alteregoizm/qna2/pulls/15","_links":{"self":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/comments/81501122"},"html":{"href":"https://github.com/alteregoizm/qna2/pull/15#discussion_r81501122"},"pull_request":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/15"}}},"pull_request":{"url":"https://api.github.com/repos/alteregoizm/qna2/pulls/15","id":87632308,"html_url":"https://github.com/alteregoizm/qna2/pull/15","diff_url":"https://github.com/alteregoizm/qna2/pull/15.diff","patch_url":"https://github.com/alteregoizm/qna2/pull/15.patch","issue_url":"https://api.github.com/repos/alteregoizm/qna2/issues/15","number":15,"state":"open","locked":false,"title":"Lesson17 - done","user":{"login":"alteregoizm","id":11354098,"avatar_url":"https://avatars.githubusercontent.com/u/11354098?v=3","gravatar_id":"","url":"https://api.github.com/users/alteregoizm","html_url":"https://github.com/alteregoizm","followers_url":"https://api.github.com/users/alteregoizm/followers","following_url":"https://api.github.com/users/alteregoizm/following{/other_user}","gists_url":"https://api.github.com/users/alteregoizm/gists{/gist_id}","starred_url":"https://api.github.com/users/alteregoizm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alteregoizm/subscriptions","organizations_url":"https://api.github.com/users/alteregoizm/orgs","repos_url":"https://api.github.com/users/alteregoizm/repos","events_url":"https://api.github.com/users/alteregoizm/events{/privacy}","received_events_url":"https://api.github.com/users/alteregoizm/received_events","type":"User","site_admin":false},"body":"Lesson17 - done","created_at":"2016-10-02T12:07:52Z","updated_at":"2016-10-03T07:28:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"948e6596cf831901402bb6776bfb660c8e8cc22a","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/alteregoizm/qna2/pulls/15/commits","review_comments_url":"https://api.github.com/repos/alteregoizm/qna2/pulls/15/comments","review_comment_url":"https://api.github.com/repos/alteregoizm/qna2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alteregoizm/qna2/issues/15/comments","statuses_url":"https://api.github.com/repos/alteregoizm/qna2/statuses/d027d42a5a8c4f234acf7af133e82453ff19d795","head":{"label":"alteregoizm:Lesson17","ref":"Lesson17","sha":"d027d42a5a8c4f234acf7af133e82453ff19d795","user":{"login":"alteregoizm","id":11354098,"avatar_url":"https://avatars.githubusercontent.com/u/11354098?v=3","gravatar_id":"","url":"https://api.github.com/users/alteregoizm","html_url":"https://github.com/alteregoizm","followers_url":"https://api.github.com/users/alteregoizm/followers","following_url":"https://api.github.com/users/alteregoizm/following{/other_user}","gists_url":"https://api.github.com/users/alteregoizm/gists{/gist_id}","starred_url":"https://api.github.com/users/alteregoizm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alteregoizm/subscriptions","organizations_url":"https://api.github.com/users/alteregoizm/orgs","repos_url":"https://api.github.com/users/alteregoizm/repos","events_url":"https://api.github.com/users/alteregoizm/events{/privacy}","received_events_url":"https://api.github.com/users/alteregoizm/received_events","type":"User","site_admin":false},"repo":{"id":62317150,"name":"qna2","full_name":"alteregoizm/qna2","owner":{"login":"alteregoizm","id":11354098,"avatar_url":"https://avatars.githubusercontent.com/u/11354098?v=3","gravatar_id":"","url":"https://api.github.com/users/alteregoizm","html_url":"https://github.com/alteregoizm","followers_url":"https://api.github.com/users/alteregoizm/followers","following_url":"https://api.github.com/users/alteregoizm/following{/other_user}","gists_url":"https://api.github.com/users/alteregoizm/gists{/gist_id}","starred_url":"https://api.github.com/users/alteregoizm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alteregoizm/subscriptions","organizations_url":"https://api.github.com/users/alteregoizm/orgs","repos_url":"https://api.github.com/users/alteregoizm/repos","events_url":"https://api.github.com/users/alteregoizm/events{/privacy}","received_events_url":"https://api.github.com/users/alteregoizm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alteregoizm/qna2","description":null,"fork":false,"url":"https://api.github.com/repos/alteregoizm/qna2","forks_url":"https://api.github.com/repos/alteregoizm/qna2/forks","keys_url":"https://api.github.com/repos/alteregoizm/qna2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alteregoizm/qna2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alteregoizm/qna2/teams","hooks_url":"https://api.github.com/repos/alteregoizm/qna2/hooks","issue_events_url":"https://api.github.com/repos/alteregoizm/qna2/issues/events{/number}","events_url":"https://api.github.com/repos/alteregoizm/qna2/events","assignees_url":"https://api.github.com/repos/alteregoizm/qna2/assignees{/user}","branches_url":"https://api.github.com/repos/alteregoizm/qna2/branches{/branch}","tags_url":"https://api.github.com/repos/alteregoizm/qna2/tags","blobs_url":"https://api.github.com/repos/alteregoizm/qna2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alteregoizm/qna2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alteregoizm/qna2/git/refs{/sha}","trees_url":"https://api.github.com/repos/alteregoizm/qna2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alteregoizm/qna2/statuses/{sha}","languages_url":"https://api.github.com/repos/alteregoizm/qna2/languages","stargazers_url":"https://api.github.com/repos/alteregoizm/qna2/stargazers","contributors_url":"https://api.github.com/repos/alteregoizm/qna2/contributors","subscribers_url":"https://api.github.com/repos/alteregoizm/qna2/subscribers","subscription_url":"https://api.github.com/repos/alteregoizm/qna2/subscription","commits_url":"https://api.github.com/repos/alteregoizm/qna2/commits{/sha}","git_commits_url":"https://api.github.com/repos/alteregoizm/qna2/git/commits{/sha}","comments_url":"https://api.github.com/repos/alteregoizm/qna2/comments{/number}","issue_comment_url":"https://api.github.com/repos/alteregoizm/qna2/issues/comments{/number}","contents_url":"https://api.github.com/repos/alteregoizm/qna2/contents/{+path}","compare_url":"https://api.github.com/repos/alteregoizm/qna2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alteregoizm/qna2/merges","archive_url":"https://api.github.com/repos/alteregoizm/qna2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alteregoizm/qna2/downloads","issues_url":"https://api.github.com/repos/alteregoizm/qna2/issues{/number}","pulls_url":"https://api.github.com/repos/alteregoizm/qna2/pulls{/number}","milestones_url":"https://api.github.com/repos/alteregoizm/qna2/milestones{/number}","notifications_url":"https://api.github.com/repos/alteregoizm/qna2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alteregoizm/qna2/labels{/name}","releases_url":"https://api.github.com/repos/alteregoizm/qna2/releases{/id}","deployments_url":"https://api.github.com/repos/alteregoizm/qna2/deployments","created_at":"2016-06-30T14:28:43Z","updated_at":"2016-06-30T14:29:18Z","pushed_at":"2016-10-03T07:16:44Z","git_url":"git://github.com/alteregoizm/qna2.git","ssh_url":"git@github.com:alteregoizm/qna2.git","clone_url":"https://github.com/alteregoizm/qna2.git","svn_url":"https://github.com/alteregoizm/qna2","homepage":null,"size":173,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"alteregoizm:master","ref":"master","sha":"a9bbdd80b0a2fa41bd8260d6197b6ee27befafda","user":{"login":"alteregoizm","id":11354098,"avatar_url":"https://avatars.githubusercontent.com/u/11354098?v=3","gravatar_id":"","url":"https://api.github.com/users/alteregoizm","html_url":"https://github.com/alteregoizm","followers_url":"https://api.github.com/users/alteregoizm/followers","following_url":"https://api.github.com/users/alteregoizm/following{/other_user}","gists_url":"https://api.github.com/users/alteregoizm/gists{/gist_id}","starred_url":"https://api.github.com/users/alteregoizm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alteregoizm/subscriptions","organizations_url":"https://api.github.com/users/alteregoizm/orgs","repos_url":"https://api.github.com/users/alteregoizm/repos","events_url":"https://api.github.com/users/alteregoizm/events{/privacy}","received_events_url":"https://api.github.com/users/alteregoizm/received_events","type":"User","site_admin":false},"repo":{"id":62317150,"name":"qna2","full_name":"alteregoizm/qna2","owner":{"login":"alteregoizm","id":11354098,"avatar_url":"https://avatars.githubusercontent.com/u/11354098?v=3","gravatar_id":"","url":"https://api.github.com/users/alteregoizm","html_url":"https://github.com/alteregoizm","followers_url":"https://api.github.com/users/alteregoizm/followers","following_url":"https://api.github.com/users/alteregoizm/following{/other_user}","gists_url":"https://api.github.com/users/alteregoizm/gists{/gist_id}","starred_url":"https://api.github.com/users/alteregoizm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alteregoizm/subscriptions","organizations_url":"https://api.github.com/users/alteregoizm/orgs","repos_url":"https://api.github.com/users/alteregoizm/repos","events_url":"https://api.github.com/users/alteregoizm/events{/privacy}","received_events_url":"https://api.github.com/users/alteregoizm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alteregoizm/qna2","description":null,"fork":false,"url":"https://api.github.com/repos/alteregoizm/qna2","forks_url":"https://api.github.com/repos/alteregoizm/qna2/forks","keys_url":"https://api.github.com/repos/alteregoizm/qna2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alteregoizm/qna2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alteregoizm/qna2/teams","hooks_url":"https://api.github.com/repos/alteregoizm/qna2/hooks","issue_events_url":"https://api.github.com/repos/alteregoizm/qna2/issues/events{/number}","events_url":"https://api.github.com/repos/alteregoizm/qna2/events","assignees_url":"https://api.github.com/repos/alteregoizm/qna2/assignees{/user}","branches_url":"https://api.github.com/repos/alteregoizm/qna2/branches{/branch}","tags_url":"https://api.github.com/repos/alteregoizm/qna2/tags","blobs_url":"https://api.github.com/repos/alteregoizm/qna2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alteregoizm/qna2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alteregoizm/qna2/git/refs{/sha}","trees_url":"https://api.github.com/repos/alteregoizm/qna2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alteregoizm/qna2/statuses/{sha}","languages_url":"https://api.github.com/repos/alteregoizm/qna2/languages","stargazers_url":"https://api.github.com/repos/alteregoizm/qna2/stargazers","contributors_url":"https://api.github.com/repos/alteregoizm/qna2/contributors","subscribers_url":"https://api.github.com/repos/alteregoizm/qna2/subscribers","subscription_url":"https://api.github.com/repos/alteregoizm/qna2/subscription","commits_url":"https://api.github.com/repos/alteregoizm/qna2/commits{/sha}","git_commits_url":"https://api.github.com/repos/alteregoizm/qna2/git/commits{/sha}","comments_url":"https://api.github.com/repos/alteregoizm/qna2/comments{/number}","issue_comment_url":"https://api.github.com/repos/alteregoizm/qna2/issues/comments{/number}","contents_url":"https://api.github.com/repos/alteregoizm/qna2/contents/{+path}","compare_url":"https://api.github.com/repos/alteregoizm/qna2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alteregoizm/qna2/merges","archive_url":"https://api.github.com/repos/alteregoizm/qna2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alteregoizm/qna2/downloads","issues_url":"https://api.github.com/repos/alteregoizm/qna2/issues{/number}","pulls_url":"https://api.github.com/repos/alteregoizm/qna2/pulls{/number}","milestones_url":"https://api.github.com/repos/alteregoizm/qna2/milestones{/number}","notifications_url":"https://api.github.com/repos/alteregoizm/qna2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alteregoizm/qna2/labels{/name}","releases_url":"https://api.github.com/repos/alteregoizm/qna2/releases{/id}","deployments_url":"https://api.github.com/repos/alteregoizm/qna2/deployments","created_at":"2016-06-30T14:28:43Z","updated_at":"2016-06-30T14:29:18Z","pushed_at":"2016-10-03T07:16:44Z","git_url":"git://github.com/alteregoizm/qna2.git","ssh_url":"git@github.com:alteregoizm/qna2.git","clone_url":"https://github.com/alteregoizm/qna2.git","svn_url":"https://github.com/alteregoizm/qna2","homepage":null,"size":173,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/15"},"html":{"href":"https://github.com/alteregoizm/qna2/pull/15"},"issue":{"href":"https://api.github.com/repos/alteregoizm/qna2/issues/15"},"comments":{"href":"https://api.github.com/repos/alteregoizm/qna2/issues/15/comments"},"review_comments":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/15/comments"},"review_comment":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alteregoizm/qna2/pulls/15/commits"},"statuses":{"href":"https://api.github.com/repos/alteregoizm/qna2/statuses/d027d42a5a8c4f234acf7af133e82453ff19d795"}}}}
{"actor":{"display_login":"vkurennov"}}