{"action":"created","comment":{"url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/comments/241666436","pull_request_review_id":184996293,"id":241666436,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI0MTY2NjQzNg==","diff_hunk":"@@ -0,0 +1,17 @@\n+class Micropost < ApplicationRecord\n+  belongs_to :user\n+  scope :order_by_desc, -> {order(created_at: :desc)}\n+  mount_uploader :picture, PictureUploader\n+  validates :user_id, presence: true\n+  validates :content, presence: true, length: {maximum: Settings.post_max_lengh}\n+  validate  :picture_size\n+\n+  private\n+\n+  def picture_size\n+    if picture.size > Settings.picture_size_max.megabytes\n+      errors.add :picture, \"should be less than 5MB\"","path":"app/models/micropost.rb","position":13,"original_position":13,"commit_id":"0f8195831b22bda4ce7a86e934eefbf7b25ca002","original_commit_id":"0f8195831b22bda4ce7a86e934eefbf7b25ca002","user":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"body":"I18n không hỗ trợ trong models ạ","created_at":"2018-12-14T07:48:39Z","updated_at":"2018-12-14T07:48:39Z","html_url":"https://github.com/iamPhong/Sample_app/pull/11#discussion_r241666436","pull_request_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/comments/241666436"},"html":{"href":"https://github.com/iamPhong/Sample_app/pull/11#discussion_r241666436"},"pull_request":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11"}},"in_reply_to_id":241656771},"pull_request":{"url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11","id":238262311,"node_id":"MDExOlB1bGxSZXF1ZXN0MjM4MjYyMzEx","html_url":"https://github.com/iamPhong/Sample_app/pull/11","diff_url":"https://github.com/iamPhong/Sample_app/pull/11.diff","patch_url":"https://github.com/iamPhong/Sample_app/pull/11.patch","issue_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/11","number":11,"state":"open","locked":false,"title":"Micropost","user":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-12-13T04:34:10Z","updated_at":"2018-12-14T07:48:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0d53466648d20ed7e8fb62656fceedb1e8775422","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11/commits","review_comments_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11/comments","review_comment_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls/comments{/number}","comments_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/11/comments","statuses_url":"https://api.github.com/repos/iamPhong/Sample_app/statuses/0f8195831b22bda4ce7a86e934eefbf7b25ca002","head":{"label":"iamPhong:User-microposts","ref":"User-microposts","sha":"0f8195831b22bda4ce7a86e934eefbf7b25ca002","user":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"repo":{"id":158351184,"node_id":"MDEwOlJlcG9zaXRvcnkxNTgzNTExODQ=","name":"Sample_app","full_name":"iamPhong/Sample_app","private":false,"owner":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"html_url":"https://github.com/iamPhong/Sample_app","description":null,"fork":false,"url":"https://api.github.com/repos/iamPhong/Sample_app","forks_url":"https://api.github.com/repos/iamPhong/Sample_app/forks","keys_url":"https://api.github.com/repos/iamPhong/Sample_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/iamPhong/Sample_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/iamPhong/Sample_app/teams","hooks_url":"https://api.github.com/repos/iamPhong/Sample_app/hooks","issue_events_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/events{/number}","events_url":"https://api.github.com/repos/iamPhong/Sample_app/events","assignees_url":"https://api.github.com/repos/iamPhong/Sample_app/assignees{/user}","branches_url":"https://api.github.com/repos/iamPhong/Sample_app/branches{/branch}","tags_url":"https://api.github.com/repos/iamPhong/Sample_app/tags","blobs_url":"https://api.github.com/repos/iamPhong/Sample_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/iamPhong/Sample_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/iamPhong/Sample_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/iamPhong/Sample_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/iamPhong/Sample_app/statuses/{sha}","languages_url":"https://api.github.com/repos/iamPhong/Sample_app/languages","stargazers_url":"https://api.github.com/repos/iamPhong/Sample_app/stargazers","contributors_url":"https://api.github.com/repos/iamPhong/Sample_app/contributors","subscribers_url":"https://api.github.com/repos/iamPhong/Sample_app/subscribers","subscription_url":"https://api.github.com/repos/iamPhong/Sample_app/subscription","commits_url":"https://api.github.com/repos/iamPhong/Sample_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/iamPhong/Sample_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/iamPhong/Sample_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/iamPhong/Sample_app/contents/{+path}","compare_url":"https://api.github.com/repos/iamPhong/Sample_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/iamPhong/Sample_app/merges","archive_url":"https://api.github.com/repos/iamPhong/Sample_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/iamPhong/Sample_app/downloads","issues_url":"https://api.github.com/repos/iamPhong/Sample_app/issues{/number}","pulls_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls{/number}","milestones_url":"https://api.github.com/repos/iamPhong/Sample_app/milestones{/number}","notifications_url":"https://api.github.com/repos/iamPhong/Sample_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/iamPhong/Sample_app/labels{/name}","releases_url":"https://api.github.com/repos/iamPhong/Sample_app/releases{/id}","deployments_url":"https://api.github.com/repos/iamPhong/Sample_app/deployments","created_at":"2018-11-20T07:53:36Z","updated_at":"2018-12-11T09:36:44Z","pushed_at":"2018-12-14T06:33:48Z","git_url":"git://github.com/iamPhong/Sample_app.git","ssh_url":"git@github.com:iamPhong/Sample_app.git","clone_url":"https://github.com/iamPhong/Sample_app.git","svn_url":"https://github.com/iamPhong/Sample_app","homepage":null,"size":240,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"iamPhong:master","ref":"master","sha":"e47cd912d1909b2c84382fa960f1923f57301ec5","user":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"repo":{"id":158351184,"node_id":"MDEwOlJlcG9zaXRvcnkxNTgzNTExODQ=","name":"Sample_app","full_name":"iamPhong/Sample_app","private":false,"owner":{"login":"iamPhong","id":44956177,"node_id":"MDQ6VXNlcjQ0OTU2MTc3","avatar_url":"https://avatars3.githubusercontent.com/u/44956177?v=4","gravatar_id":"","url":"https://api.github.com/users/iamPhong","html_url":"https://github.com/iamPhong","followers_url":"https://api.github.com/users/iamPhong/followers","following_url":"https://api.github.com/users/iamPhong/following{/other_user}","gists_url":"https://api.github.com/users/iamPhong/gists{/gist_id}","starred_url":"https://api.github.com/users/iamPhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iamPhong/subscriptions","organizations_url":"https://api.github.com/users/iamPhong/orgs","repos_url":"https://api.github.com/users/iamPhong/repos","events_url":"https://api.github.com/users/iamPhong/events{/privacy}","received_events_url":"https://api.github.com/users/iamPhong/received_events","type":"User","site_admin":false},"html_url":"https://github.com/iamPhong/Sample_app","description":null,"fork":false,"url":"https://api.github.com/repos/iamPhong/Sample_app","forks_url":"https://api.github.com/repos/iamPhong/Sample_app/forks","keys_url":"https://api.github.com/repos/iamPhong/Sample_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/iamPhong/Sample_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/iamPhong/Sample_app/teams","hooks_url":"https://api.github.com/repos/iamPhong/Sample_app/hooks","issue_events_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/events{/number}","events_url":"https://api.github.com/repos/iamPhong/Sample_app/events","assignees_url":"https://api.github.com/repos/iamPhong/Sample_app/assignees{/user}","branches_url":"https://api.github.com/repos/iamPhong/Sample_app/branches{/branch}","tags_url":"https://api.github.com/repos/iamPhong/Sample_app/tags","blobs_url":"https://api.github.com/repos/iamPhong/Sample_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/iamPhong/Sample_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/iamPhong/Sample_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/iamPhong/Sample_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/iamPhong/Sample_app/statuses/{sha}","languages_url":"https://api.github.com/repos/iamPhong/Sample_app/languages","stargazers_url":"https://api.github.com/repos/iamPhong/Sample_app/stargazers","contributors_url":"https://api.github.com/repos/iamPhong/Sample_app/contributors","subscribers_url":"https://api.github.com/repos/iamPhong/Sample_app/subscribers","subscription_url":"https://api.github.com/repos/iamPhong/Sample_app/subscription","commits_url":"https://api.github.com/repos/iamPhong/Sample_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/iamPhong/Sample_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/iamPhong/Sample_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/iamPhong/Sample_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/iamPhong/Sample_app/contents/{+path}","compare_url":"https://api.github.com/repos/iamPhong/Sample_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/iamPhong/Sample_app/merges","archive_url":"https://api.github.com/repos/iamPhong/Sample_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/iamPhong/Sample_app/downloads","issues_url":"https://api.github.com/repos/iamPhong/Sample_app/issues{/number}","pulls_url":"https://api.github.com/repos/iamPhong/Sample_app/pulls{/number}","milestones_url":"https://api.github.com/repos/iamPhong/Sample_app/milestones{/number}","notifications_url":"https://api.github.com/repos/iamPhong/Sample_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/iamPhong/Sample_app/labels{/name}","releases_url":"https://api.github.com/repos/iamPhong/Sample_app/releases{/id}","deployments_url":"https://api.github.com/repos/iamPhong/Sample_app/deployments","created_at":"2018-11-20T07:53:36Z","updated_at":"2018-12-11T09:36:44Z","pushed_at":"2018-12-14T06:33:48Z","git_url":"git://github.com/iamPhong/Sample_app.git","ssh_url":"git@github.com:iamPhong/Sample_app.git","clone_url":"https://github.com/iamPhong/Sample_app.git","svn_url":"https://github.com/iamPhong/Sample_app","homepage":null,"size":240,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11"},"html":{"href":"https://github.com/iamPhong/Sample_app/pull/11"},"issue":{"href":"https://api.github.com/repos/iamPhong/Sample_app/issues/11"},"comments":{"href":"https://api.github.com/repos/iamPhong/Sample_app/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/iamPhong/Sample_app/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/iamPhong/Sample_app/statuses/0f8195831b22bda4ce7a86e934eefbf7b25ca002"}},"author_association":"OWNER"}}
{"actor":{"display_login":"iamPhong"}}