{"action":"created","comment":{"url":"https://api.github.com/repos/sachmem/els4/pulls/comments/71111837","id":71111837,"diff_hunk":"@@ -0,0 +1,21 @@\n+class SessionsController < ApplicationController\n+\n+  def new\n+  end\n+\n+  def create\n+    user = User.find_by(email: params[:session][:email].downcase)\n+    if user && user.authenticate(params[:session][:password])\n+      log_in user\n+      redirect_to user\n+    else\n+      flash.now[:danger] = \"Invalid email/password combination\"","path":"app/controllers/sessions_controller.rb","position":12,"original_position":12,"commit_id":"a66dda4da57d1a1607e66caac113b68c0294d54b","original_commit_id":"a66dda4da57d1a1607e66caac113b68c0294d54b","user":{"login":"ttuan","id":10399018,"avatar_url":"https://avatars.githubusercontent.com/u/10399018?v=3","gravatar_id":"","url":"https://api.github.com/users/ttuan","html_url":"https://github.com/ttuan","followers_url":"https://api.github.com/users/ttuan/followers","following_url":"https://api.github.com/users/ttuan/following{/other_user}","gists_url":"https://api.github.com/users/ttuan/gists{/gist_id}","starred_url":"https://api.github.com/users/ttuan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttuan/subscriptions","organizations_url":"https://api.github.com/users/ttuan/orgs","repos_url":"https://api.github.com/users/ttuan/repos","events_url":"https://api.github.com/users/ttuan/events{/privacy}","received_events_url":"https://api.github.com/users/ttuan/received_events","type":"User","site_admin":false},"body":"i18n","created_at":"2016-07-18T08:16:06Z","updated_at":"2016-07-18T08:16:06Z","html_url":"https://github.com/sachmem/els4/pull/21#discussion_r71111837","pull_request_url":"https://api.github.com/repos/sachmem/els4/pulls/21","_links":{"self":{"href":"https://api.github.com/repos/sachmem/els4/pulls/comments/71111837"},"html":{"href":"https://github.com/sachmem/els4/pull/21#discussion_r71111837"},"pull_request":{"href":"https://api.github.com/repos/sachmem/els4/pulls/21"}}},"pull_request":{"url":"https://api.github.com/repos/sachmem/els4/pulls/21","id":77770530,"html_url":"https://github.com/sachmem/els4/pull/21","diff_url":"https://github.com/sachmem/els4/pull/21.diff","patch_url":"https://github.com/sachmem/els4/pull/21.patch","issue_url":"https://api.github.com/repos/sachmem/els4/issues/21","number":21,"state":"open","locked":false,"title":"session-login","user":{"login":"ngockha96","id":17715003,"avatar_url":"https://avatars.githubusercontent.com/u/17715003?v=3","gravatar_id":"","url":"https://api.github.com/users/ngockha96","html_url":"https://github.com/ngockha96","followers_url":"https://api.github.com/users/ngockha96/followers","following_url":"https://api.github.com/users/ngockha96/following{/other_user}","gists_url":"https://api.github.com/users/ngockha96/gists{/gist_id}","starred_url":"https://api.github.com/users/ngockha96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngockha96/subscriptions","organizations_url":"https://api.github.com/users/ngockha96/orgs","repos_url":"https://api.github.com/users/ngockha96/repos","events_url":"https://api.github.com/users/ngockha96/events{/privacy}","received_events_url":"https://api.github.com/users/ngockha96/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-07-18T07:56:27Z","updated_at":"2016-07-18T08:16:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cedb11b8a49e50fb463555693e98d688b449b220","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/sachmem/els4/pulls/21/commits","review_comments_url":"https://api.github.com/repos/sachmem/els4/pulls/21/comments","review_comment_url":"https://api.github.com/repos/sachmem/els4/pulls/comments{/number}","comments_url":"https://api.github.com/repos/sachmem/els4/issues/21/comments","statuses_url":"https://api.github.com/repos/sachmem/els4/statuses/a66dda4da57d1a1607e66caac113b68c0294d54b","head":{"label":"ngockha96:session-login","ref":"session-login","sha":"a66dda4da57d1a1607e66caac113b68c0294d54b","user":{"login":"ngockha96","id":17715003,"avatar_url":"https://avatars.githubusercontent.com/u/17715003?v=3","gravatar_id":"","url":"https://api.github.com/users/ngockha96","html_url":"https://github.com/ngockha96","followers_url":"https://api.github.com/users/ngockha96/followers","following_url":"https://api.github.com/users/ngockha96/following{/other_user}","gists_url":"https://api.github.com/users/ngockha96/gists{/gist_id}","starred_url":"https://api.github.com/users/ngockha96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngockha96/subscriptions","organizations_url":"https://api.github.com/users/ngockha96/orgs","repos_url":"https://api.github.com/users/ngockha96/repos","events_url":"https://api.github.com/users/ngockha96/events{/privacy}","received_events_url":"https://api.github.com/users/ngockha96/received_events","type":"User","site_admin":false},"repo":{"id":63214674,"name":"els4","full_name":"ngockha96/els4","owner":{"login":"ngockha96","id":17715003,"avatar_url":"https://avatars.githubusercontent.com/u/17715003?v=3","gravatar_id":"","url":"https://api.github.com/users/ngockha96","html_url":"https://github.com/ngockha96","followers_url":"https://api.github.com/users/ngockha96/followers","following_url":"https://api.github.com/users/ngockha96/following{/other_user}","gists_url":"https://api.github.com/users/ngockha96/gists{/gist_id}","starred_url":"https://api.github.com/users/ngockha96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngockha96/subscriptions","organizations_url":"https://api.github.com/users/ngockha96/orgs","repos_url":"https://api.github.com/users/ngockha96/repos","events_url":"https://api.github.com/users/ngockha96/events{/privacy}","received_events_url":"https://api.github.com/users/ngockha96/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ngockha96/els4","description":null,"fork":true,"url":"https://api.github.com/repos/ngockha96/els4","forks_url":"https://api.github.com/repos/ngockha96/els4/forks","keys_url":"https://api.github.com/repos/ngockha96/els4/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ngockha96/els4/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ngockha96/els4/teams","hooks_url":"https://api.github.com/repos/ngockha96/els4/hooks","issue_events_url":"https://api.github.com/repos/ngockha96/els4/issues/events{/number}","events_url":"https://api.github.com/repos/ngockha96/els4/events","assignees_url":"https://api.github.com/repos/ngockha96/els4/assignees{/user}","branches_url":"https://api.github.com/repos/ngockha96/els4/branches{/branch}","tags_url":"https://api.github.com/repos/ngockha96/els4/tags","blobs_url":"https://api.github.com/repos/ngockha96/els4/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ngockha96/els4/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ngockha96/els4/git/refs{/sha}","trees_url":"https://api.github.com/repos/ngockha96/els4/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ngockha96/els4/statuses/{sha}","languages_url":"https://api.github.com/repos/ngockha96/els4/languages","stargazers_url":"https://api.github.com/repos/ngockha96/els4/stargazers","contributors_url":"https://api.github.com/repos/ngockha96/els4/contributors","subscribers_url":"https://api.github.com/repos/ngockha96/els4/subscribers","subscription_url":"https://api.github.com/repos/ngockha96/els4/subscription","commits_url":"https://api.github.com/repos/ngockha96/els4/commits{/sha}","git_commits_url":"https://api.github.com/repos/ngockha96/els4/git/commits{/sha}","comments_url":"https://api.github.com/repos/ngockha96/els4/comments{/number}","issue_comment_url":"https://api.github.com/repos/ngockha96/els4/issues/comments{/number}","contents_url":"https://api.github.com/repos/ngockha96/els4/contents/{+path}","compare_url":"https://api.github.com/repos/ngockha96/els4/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ngockha96/els4/merges","archive_url":"https://api.github.com/repos/ngockha96/els4/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ngockha96/els4/downloads","issues_url":"https://api.github.com/repos/ngockha96/els4/issues{/number}","pulls_url":"https://api.github.com/repos/ngockha96/els4/pulls{/number}","milestones_url":"https://api.github.com/repos/ngockha96/els4/milestones{/number}","notifications_url":"https://api.github.com/repos/ngockha96/els4/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ngockha96/els4/labels{/name}","releases_url":"https://api.github.com/repos/ngockha96/els4/releases{/id}","deployments_url":"https://api.github.com/repos/ngockha96/els4/deployments","created_at":"2016-07-13T04:37:31Z","updated_at":"2016-07-13T04:37:32Z","pushed_at":"2016-07-18T08:13:25Z","git_url":"git://github.com/ngockha96/els4.git","ssh_url":"git@github.com:ngockha96/els4.git","clone_url":"https://github.com/ngockha96/els4.git","svn_url":"https://github.com/ngockha96/els4","homepage":null,"size":21,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":"sachmem:development","ref":"development","sha":"62f57d51a937089fb15a0ca8418de058706b6ae9","user":{"login":"sachmem","id":20066220,"avatar_url":"https://avatars.githubusercontent.com/u/20066220?v=3","gravatar_id":"","url":"https://api.github.com/users/sachmem","html_url":"https://github.com/sachmem","followers_url":"https://api.github.com/users/sachmem/followers","following_url":"https://api.github.com/users/sachmem/following{/other_user}","gists_url":"https://api.github.com/users/sachmem/gists{/gist_id}","starred_url":"https://api.github.com/users/sachmem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sachmem/subscriptions","organizations_url":"https://api.github.com/users/sachmem/orgs","repos_url":"https://api.github.com/users/sachmem/repos","events_url":"https://api.github.com/users/sachmem/events{/privacy}","received_events_url":"https://api.github.com/users/sachmem/received_events","type":"Organization","site_admin":false},"repo":{"id":63213575,"name":"els4","full_name":"sachmem/els4","owner":{"login":"sachmem","id":20066220,"avatar_url":"https://avatars.githubusercontent.com/u/20066220?v=3","gravatar_id":"","url":"https://api.github.com/users/sachmem","html_url":"https://github.com/sachmem","followers_url":"https://api.github.com/users/sachmem/followers","following_url":"https://api.github.com/users/sachmem/following{/other_user}","gists_url":"https://api.github.com/users/sachmem/gists{/gist_id}","starred_url":"https://api.github.com/users/sachmem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sachmem/subscriptions","organizations_url":"https://api.github.com/users/sachmem/orgs","repos_url":"https://api.github.com/users/sachmem/repos","events_url":"https://api.github.com/users/sachmem/events{/privacy}","received_events_url":"https://api.github.com/users/sachmem/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sachmem/els4","description":null,"fork":false,"url":"https://api.github.com/repos/sachmem/els4","forks_url":"https://api.github.com/repos/sachmem/els4/forks","keys_url":"https://api.github.com/repos/sachmem/els4/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sachmem/els4/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sachmem/els4/teams","hooks_url":"https://api.github.com/repos/sachmem/els4/hooks","issue_events_url":"https://api.github.com/repos/sachmem/els4/issues/events{/number}","events_url":"https://api.github.com/repos/sachmem/els4/events","assignees_url":"https://api.github.com/repos/sachmem/els4/assignees{/user}","branches_url":"https://api.github.com/repos/sachmem/els4/branches{/branch}","tags_url":"https://api.github.com/repos/sachmem/els4/tags","blobs_url":"https://api.github.com/repos/sachmem/els4/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sachmem/els4/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sachmem/els4/git/refs{/sha}","trees_url":"https://api.github.com/repos/sachmem/els4/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sachmem/els4/statuses/{sha}","languages_url":"https://api.github.com/repos/sachmem/els4/languages","stargazers_url":"https://api.github.com/repos/sachmem/els4/stargazers","contributors_url":"https://api.github.com/repos/sachmem/els4/contributors","subscribers_url":"https://api.github.com/repos/sachmem/els4/subscribers","subscription_url":"https://api.github.com/repos/sachmem/els4/subscription","commits_url":"https://api.github.com/repos/sachmem/els4/commits{/sha}","git_commits_url":"https://api.github.com/repos/sachmem/els4/git/commits{/sha}","comments_url":"https://api.github.com/repos/sachmem/els4/comments{/number}","issue_comment_url":"https://api.github.com/repos/sachmem/els4/issues/comments{/number}","contents_url":"https://api.github.com/repos/sachmem/els4/contents/{+path}","compare_url":"https://api.github.com/repos/sachmem/els4/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sachmem/els4/merges","archive_url":"https://api.github.com/repos/sachmem/els4/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sachmem/els4/downloads","issues_url":"https://api.github.com/repos/sachmem/els4/issues{/number}","pulls_url":"https://api.github.com/repos/sachmem/els4/pulls{/number}","milestones_url":"https://api.github.com/repos/sachmem/els4/milestones{/number}","notifications_url":"https://api.github.com/repos/sachmem/els4/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sachmem/els4/labels{/name}","releases_url":"https://api.github.com/repos/sachmem/els4/releases{/id}","deployments_url":"https://api.github.com/repos/sachmem/els4/deployments","created_at":"2016-07-13T04:12:29Z","updated_at":"2016-07-13T04:18:08Z","pushed_at":"2016-07-18T08:13:26Z","git_url":"git://github.com/sachmem/els4.git","ssh_url":"git@github.com:sachmem/els4.git","clone_url":"https://github.com/sachmem/els4.git","svn_url":"https://github.com/sachmem/els4","homepage":null,"size":49,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":2,"forks":3,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/sachmem/els4/pulls/21"},"html":{"href":"https://github.com/sachmem/els4/pull/21"},"issue":{"href":"https://api.github.com/repos/sachmem/els4/issues/21"},"comments":{"href":"https://api.github.com/repos/sachmem/els4/issues/21/comments"},"review_comments":{"href":"https://api.github.com/repos/sachmem/els4/pulls/21/comments"},"review_comment":{"href":"https://api.github.com/repos/sachmem/els4/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/sachmem/els4/pulls/21/commits"},"statuses":{"href":"https://api.github.com/repos/sachmem/els4/statuses/a66dda4da57d1a1607e66caac113b68c0294d54b"}}}}
{"actor":{"display_login":"ttuan"}}