{"action":"created","comment":{"url":"https://api.github.com/repos/framgia/tms_15/pulls/comments/24288264","id":24288264,"diff_hunk":"@@ -1,2 +1,10 @@\n class User < ActiveRecord::Base\n+  before_save {self.email = email.downcase}\n+  validates :name, presence: true, length: {maximum: 50}\n+  VALID_EMAIL_REGEX = /\\A[\\w+\\-.]+@[a-z\\d\\-.]+\\.[a-z]+\\z/i\n+  validates :email, presence: true, length: {maximum: 255},\n+  format: {with: VALID_EMAIL_REGEX},\n+  uniqueness: {case_sensitive: false}","path":"app/models/user.rb","position":7,"original_position":7,"commit_id":"9a655ed87250c7179ce5d0449ac7e4eecbd246c5","original_commit_id":"9a655ed87250c7179ce5d0449ac7e4eecbd246c5","user":{"login":"dieunb","id":2122175,"avatar_url":"https://avatars.githubusercontent.com/u/2122175?v=3","gravatar_id":"","url":"https://api.github.com/users/dieunb","html_url":"https://github.com/dieunb","followers_url":"https://api.github.com/users/dieunb/followers","following_url":"https://api.github.com/users/dieunb/following{/other_user}","gists_url":"https://api.github.com/users/dieunb/gists{/gist_id}","starred_url":"https://api.github.com/users/dieunb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dieunb/subscriptions","organizations_url":"https://api.github.com/users/dieunb/orgs","repos_url":"https://api.github.com/users/dieunb/repos","events_url":"https://api.github.com/users/dieunb/events{/privacy}","received_events_url":"https://api.github.com/users/dieunb/received_events","type":"User","site_admin":false},"body":"indent ","created_at":"2015-02-07T09:08:04Z","updated_at":"2015-02-07T09:08:04Z","html_url":"https://github.com/framgia/tms_15/pull/6#discussion_r24288264","pull_request_url":"https://api.github.com/repos/framgia/tms_15/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/comments/24288264"},"html":{"href":"https://github.com/framgia/tms_15/pull/6#discussion_r24288264"},"pull_request":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/framgia/tms_15/pulls/6","id":28860987,"html_url":"https://github.com/framgia/tms_15/pull/6","diff_url":"https://github.com/framgia/tms_15/pull/6.diff","patch_url":"https://github.com/framgia/tms_15/pull/6.patch","issue_url":"https://api.github.com/repos/framgia/tms_15/issues/6","number":6,"state":"open","locked":false,"title":"Add Users controller, signup","user":{"login":"nhieu92","id":10509903,"avatar_url":"https://avatars.githubusercontent.com/u/10509903?v=3","gravatar_id":"","url":"https://api.github.com/users/nhieu92","html_url":"https://github.com/nhieu92","followers_url":"https://api.github.com/users/nhieu92/followers","following_url":"https://api.github.com/users/nhieu92/following{/other_user}","gists_url":"https://api.github.com/users/nhieu92/gists{/gist_id}","starred_url":"https://api.github.com/users/nhieu92/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nhieu92/subscriptions","organizations_url":"https://api.github.com/users/nhieu92/orgs","repos_url":"https://api.github.com/users/nhieu92/repos","events_url":"https://api.github.com/users/nhieu92/events{/privacy}","received_events_url":"https://api.github.com/users/nhieu92/received_events","type":"User","site_admin":false},"body":"Add Users controller, signup","created_at":"2015-02-07T08:09:16Z","updated_at":"2015-02-07T09:08:04Z","closed_at":null,"merged_at":null,"merge_commit_sha":"103f80f9098986bbd930b3e9000e2aae57cf112b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/framgia/tms_15/pulls/6/commits","review_comments_url":"https://api.github.com/repos/framgia/tms_15/pulls/6/comments","review_comment_url":"https://api.github.com/repos/framgia/tms_15/pulls/comments/{number}","comments_url":"https://api.github.com/repos/framgia/tms_15/issues/6/comments","statuses_url":"https://api.github.com/repos/framgia/tms_15/statuses/9a655ed87250c7179ce5d0449ac7e4eecbd246c5","head":{"label":"nhieu92:sign-up","ref":"sign-up","sha":"9a655ed87250c7179ce5d0449ac7e4eecbd246c5","user":{"login":"nhieu92","id":10509903,"avatar_url":"https://avatars.githubusercontent.com/u/10509903?v=3","gravatar_id":"","url":"https://api.github.com/users/nhieu92","html_url":"https://github.com/nhieu92","followers_url":"https://api.github.com/users/nhieu92/followers","following_url":"https://api.github.com/users/nhieu92/following{/other_user}","gists_url":"https://api.github.com/users/nhieu92/gists{/gist_id}","starred_url":"https://api.github.com/users/nhieu92/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nhieu92/subscriptions","organizations_url":"https://api.github.com/users/nhieu92/orgs","repos_url":"https://api.github.com/users/nhieu92/repos","events_url":"https://api.github.com/users/nhieu92/events{/privacy}","received_events_url":"https://api.github.com/users/nhieu92/received_events","type":"User","site_admin":false},"repo":{"id":30447580,"name":"tms_15","full_name":"nhieu92/tms_15","owner":{"login":"nhieu92","id":10509903,"avatar_url":"https://avatars.githubusercontent.com/u/10509903?v=3","gravatar_id":"","url":"https://api.github.com/users/nhieu92","html_url":"https://github.com/nhieu92","followers_url":"https://api.github.com/users/nhieu92/followers","following_url":"https://api.github.com/users/nhieu92/following{/other_user}","gists_url":"https://api.github.com/users/nhieu92/gists{/gist_id}","starred_url":"https://api.github.com/users/nhieu92/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nhieu92/subscriptions","organizations_url":"https://api.github.com/users/nhieu92/orgs","repos_url":"https://api.github.com/users/nhieu92/repos","events_url":"https://api.github.com/users/nhieu92/events{/privacy}","received_events_url":"https://api.github.com/users/nhieu92/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nhieu92/tms_15","description":"Framgia Training Management System (training)","fork":true,"url":"https://api.github.com/repos/nhieu92/tms_15","forks_url":"https://api.github.com/repos/nhieu92/tms_15/forks","keys_url":"https://api.github.com/repos/nhieu92/tms_15/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nhieu92/tms_15/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nhieu92/tms_15/teams","hooks_url":"https://api.github.com/repos/nhieu92/tms_15/hooks","issue_events_url":"https://api.github.com/repos/nhieu92/tms_15/issues/events{/number}","events_url":"https://api.github.com/repos/nhieu92/tms_15/events","assignees_url":"https://api.github.com/repos/nhieu92/tms_15/assignees{/user}","branches_url":"https://api.github.com/repos/nhieu92/tms_15/branches{/branch}","tags_url":"https://api.github.com/repos/nhieu92/tms_15/tags","blobs_url":"https://api.github.com/repos/nhieu92/tms_15/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nhieu92/tms_15/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nhieu92/tms_15/git/refs{/sha}","trees_url":"https://api.github.com/repos/nhieu92/tms_15/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nhieu92/tms_15/statuses/{sha}","languages_url":"https://api.github.com/repos/nhieu92/tms_15/languages","stargazers_url":"https://api.github.com/repos/nhieu92/tms_15/stargazers","contributors_url":"https://api.github.com/repos/nhieu92/tms_15/contributors","subscribers_url":"https://api.github.com/repos/nhieu92/tms_15/subscribers","subscription_url":"https://api.github.com/repos/nhieu92/tms_15/subscription","commits_url":"https://api.github.com/repos/nhieu92/tms_15/commits{/sha}","git_commits_url":"https://api.github.com/repos/nhieu92/tms_15/git/commits{/sha}","comments_url":"https://api.github.com/repos/nhieu92/tms_15/comments{/number}","issue_comment_url":"https://api.github.com/repos/nhieu92/tms_15/issues/comments/{number}","contents_url":"https://api.github.com/repos/nhieu92/tms_15/contents/{+path}","compare_url":"https://api.github.com/repos/nhieu92/tms_15/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nhieu92/tms_15/merges","archive_url":"https://api.github.com/repos/nhieu92/tms_15/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nhieu92/tms_15/downloads","issues_url":"https://api.github.com/repos/nhieu92/tms_15/issues{/number}","pulls_url":"https://api.github.com/repos/nhieu92/tms_15/pulls{/number}","milestones_url":"https://api.github.com/repos/nhieu92/tms_15/milestones{/number}","notifications_url":"https://api.github.com/repos/nhieu92/tms_15/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nhieu92/tms_15/labels{/name}","releases_url":"https://api.github.com/repos/nhieu92/tms_15/releases{/id}","created_at":"2015-02-07T06:27:55Z","updated_at":"2015-01-26T01:59:05Z","pushed_at":"2015-02-07T09:02:23Z","git_url":"git://github.com/nhieu92/tms_15.git","ssh_url":"git@github.com:nhieu92/tms_15.git","clone_url":"https://github.com/nhieu92/tms_15.git","svn_url":"https://github.com/nhieu92/tms_15","homepage":null,"size":148,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"framgia:develop","ref":"develop","sha":"0371947918d4d7826b2213f7588b5c7b04ba809b","user":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"repo":{"id":29840581,"name":"tms_15","full_name":"framgia/tms_15","owner":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/framgia/tms_15","description":"Framgia Training Management System (training)","fork":false,"url":"https://api.github.com/repos/framgia/tms_15","forks_url":"https://api.github.com/repos/framgia/tms_15/forks","keys_url":"https://api.github.com/repos/framgia/tms_15/keys{/key_id}","collaborators_url":"https://api.github.com/repos/framgia/tms_15/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/framgia/tms_15/teams","hooks_url":"https://api.github.com/repos/framgia/tms_15/hooks","issue_events_url":"https://api.github.com/repos/framgia/tms_15/issues/events{/number}","events_url":"https://api.github.com/repos/framgia/tms_15/events","assignees_url":"https://api.github.com/repos/framgia/tms_15/assignees{/user}","branches_url":"https://api.github.com/repos/framgia/tms_15/branches{/branch}","tags_url":"https://api.github.com/repos/framgia/tms_15/tags","blobs_url":"https://api.github.com/repos/framgia/tms_15/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/framgia/tms_15/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/framgia/tms_15/git/refs{/sha}","trees_url":"https://api.github.com/repos/framgia/tms_15/git/trees{/sha}","statuses_url":"https://api.github.com/repos/framgia/tms_15/statuses/{sha}","languages_url":"https://api.github.com/repos/framgia/tms_15/languages","stargazers_url":"https://api.github.com/repos/framgia/tms_15/stargazers","contributors_url":"https://api.github.com/repos/framgia/tms_15/contributors","subscribers_url":"https://api.github.com/repos/framgia/tms_15/subscribers","subscription_url":"https://api.github.com/repos/framgia/tms_15/subscription","commits_url":"https://api.github.com/repos/framgia/tms_15/commits{/sha}","git_commits_url":"https://api.github.com/repos/framgia/tms_15/git/commits{/sha}","comments_url":"https://api.github.com/repos/framgia/tms_15/comments{/number}","issue_comment_url":"https://api.github.com/repos/framgia/tms_15/issues/comments/{number}","contents_url":"https://api.github.com/repos/framgia/tms_15/contents/{+path}","compare_url":"https://api.github.com/repos/framgia/tms_15/compare/{base}...{head}","merges_url":"https://api.github.com/repos/framgia/tms_15/merges","archive_url":"https://api.github.com/repos/framgia/tms_15/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/framgia/tms_15/downloads","issues_url":"https://api.github.com/repos/framgia/tms_15/issues{/number}","pulls_url":"https://api.github.com/repos/framgia/tms_15/pulls{/number}","milestones_url":"https://api.github.com/repos/framgia/tms_15/milestones{/number}","notifications_url":"https://api.github.com/repos/framgia/tms_15/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/framgia/tms_15/labels{/name}","releases_url":"https://api.github.com/repos/framgia/tms_15/releases{/id}","created_at":"2015-01-26T01:59:05Z","updated_at":"2015-01-26T01:59:05Z","pushed_at":"2015-02-07T07:11:06Z","git_url":"git://github.com/framgia/tms_15.git","ssh_url":"git@github.com:framgia/tms_15.git","clone_url":"https://github.com/framgia/tms_15.git","svn_url":"https://github.com/framgia/tms_15","homepage":null,"size":148,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":3,"forks":3,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/6"},"html":{"href":"https://github.com/framgia/tms_15/pull/6"},"issue":{"href":"https://api.github.com/repos/framgia/tms_15/issues/6"},"comments":{"href":"https://api.github.com/repos/framgia/tms_15/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/framgia/tms_15/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/framgia/tms_15/statuses/9a655ed87250c7179ce5d0449ac7e4eecbd246c5"}}}}