{"action":"created","comment":{"url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/comments/43238337","id":43238337,"diff_hunk":"@@ -1,9 +1,22 @@\n class UsersController < ApplicationController\n \n-    def new\n+  def new\n+  end\n+\n+  def create\n+    @user = User.new(user_params)\n+    if @user.save\n+      session[:user_id] = @user.id\n+      redirect_to root_path, notice: 'Account created successfully'\n+    else\n+      flash[:error] = 'An error occurred!'\n+      render 'new'\n     end\n+  end\n \n-    def create\n-    end  \n+private","path":"app/controllers/users_controller.rb","position":20,"original_position":20,"commit_id":"077bc8216293145c37dec1930991cc980526c81d","original_commit_id":"077bc8216293145c37dec1930991cc980526c81d","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Indent access modifiers like `private`.","created_at":"2015-10-28T10:29:26Z","updated_at":"2015-10-28T10:29:26Z","html_url":"https://github.com/andela-atemitope/Tushot/pull/1#discussion_r43238337","pull_request_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/comments/43238337"},"html":{"href":"https://github.com/andela-atemitope/Tushot/pull/1#discussion_r43238337"},"pull_request":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1","id":48987396,"html_url":"https://github.com/andela-atemitope/Tushot/pull/1","diff_url":"https://github.com/andela-atemitope/Tushot/pull/1.diff","patch_url":"https://github.com/andela-atemitope/Tushot/pull/1.patch","issue_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/1","number":1,"state":"open","locked":false,"title":"Authentication","user":{"login":"andela-atemitope","id":13197764,"avatar_url":"https://avatars.githubusercontent.com/u/13197764?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-atemitope","html_url":"https://github.com/andela-atemitope","followers_url":"https://api.github.com/users/andela-atemitope/followers","following_url":"https://api.github.com/users/andela-atemitope/following{/other_user}","gists_url":"https://api.github.com/users/andela-atemitope/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-atemitope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-atemitope/subscriptions","organizations_url":"https://api.github.com/users/andela-atemitope/orgs","repos_url":"https://api.github.com/users/andela-atemitope/repos","events_url":"https://api.github.com/users/andela-atemitope/events{/privacy}","received_events_url":"https://api.github.com/users/andela-atemitope/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-10-28T10:29:12Z","updated_at":"2015-10-28T10:29:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1/commits","review_comments_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1/comments","review_comment_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/1/comments","statuses_url":"https://api.github.com/repos/andela-atemitope/Tushot/statuses/077bc8216293145c37dec1930991cc980526c81d","head":{"label":"andela-atemitope:authentication","ref":"authentication","sha":"077bc8216293145c37dec1930991cc980526c81d","user":{"login":"andela-atemitope","id":13197764,"avatar_url":"https://avatars.githubusercontent.com/u/13197764?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-atemitope","html_url":"https://github.com/andela-atemitope","followers_url":"https://api.github.com/users/andela-atemitope/followers","following_url":"https://api.github.com/users/andela-atemitope/following{/other_user}","gists_url":"https://api.github.com/users/andela-atemitope/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-atemitope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-atemitope/subscriptions","organizations_url":"https://api.github.com/users/andela-atemitope/orgs","repos_url":"https://api.github.com/users/andela-atemitope/repos","events_url":"https://api.github.com/users/andela-atemitope/events{/privacy}","received_events_url":"https://api.github.com/users/andela-atemitope/received_events","type":"User","site_admin":false},"repo":{"id":45042335,"name":"Tushot","full_name":"andela-atemitope/Tushot","owner":{"login":"andela-atemitope","id":13197764,"avatar_url":"https://avatars.githubusercontent.com/u/13197764?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-atemitope","html_url":"https://github.com/andela-atemitope","followers_url":"https://api.github.com/users/andela-atemitope/followers","following_url":"https://api.github.com/users/andela-atemitope/following{/other_user}","gists_url":"https://api.github.com/users/andela-atemitope/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-atemitope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-atemitope/subscriptions","organizations_url":"https://api.github.com/users/andela-atemitope/orgs","repos_url":"https://api.github.com/users/andela-atemitope/repos","events_url":"https://api.github.com/users/andela-atemitope/events{/privacy}","received_events_url":"https://api.github.com/users/andela-atemitope/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/andela-atemitope/Tushot","description":"A Url Shortener built using Rails 4","fork":false,"url":"https://api.github.com/repos/andela-atemitope/Tushot","forks_url":"https://api.github.com/repos/andela-atemitope/Tushot/forks","keys_url":"https://api.github.com/repos/andela-atemitope/Tushot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela-atemitope/Tushot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela-atemitope/Tushot/teams","hooks_url":"https://api.github.com/repos/andela-atemitope/Tushot/hooks","issue_events_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/events{/number}","events_url":"https://api.github.com/repos/andela-atemitope/Tushot/events","assignees_url":"https://api.github.com/repos/andela-atemitope/Tushot/assignees{/user}","branches_url":"https://api.github.com/repos/andela-atemitope/Tushot/branches{/branch}","tags_url":"https://api.github.com/repos/andela-atemitope/Tushot/tags","blobs_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela-atemitope/Tushot/statuses/{sha}","languages_url":"https://api.github.com/repos/andela-atemitope/Tushot/languages","stargazers_url":"https://api.github.com/repos/andela-atemitope/Tushot/stargazers","contributors_url":"https://api.github.com/repos/andela-atemitope/Tushot/contributors","subscribers_url":"https://api.github.com/repos/andela-atemitope/Tushot/subscribers","subscription_url":"https://api.github.com/repos/andela-atemitope/Tushot/subscription","commits_url":"https://api.github.com/repos/andela-atemitope/Tushot/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela-atemitope/Tushot/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela-atemitope/Tushot/contents/{+path}","compare_url":"https://api.github.com/repos/andela-atemitope/Tushot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela-atemitope/Tushot/merges","archive_url":"https://api.github.com/repos/andela-atemitope/Tushot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela-atemitope/Tushot/downloads","issues_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues{/number}","pulls_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls{/number}","milestones_url":"https://api.github.com/repos/andela-atemitope/Tushot/milestones{/number}","notifications_url":"https://api.github.com/repos/andela-atemitope/Tushot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela-atemitope/Tushot/labels{/name}","releases_url":"https://api.github.com/repos/andela-atemitope/Tushot/releases{/id}","created_at":"2015-10-27T13:19:34Z","updated_at":"2015-10-28T10:22:07Z","pushed_at":"2015-10-28T10:29:13Z","git_url":"git://github.com/andela-atemitope/Tushot.git","ssh_url":"git@github.com:andela-atemitope/Tushot.git","clone_url":"https://github.com/andela-atemitope/Tushot.git","svn_url":"https://github.com/andela-atemitope/Tushot","homepage":null,"size":0,"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":"andela-atemitope:master","ref":"master","sha":"2cff6af2bf55f0f7d40cf27ba6e68da2e7366698","user":{"login":"andela-atemitope","id":13197764,"avatar_url":"https://avatars.githubusercontent.com/u/13197764?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-atemitope","html_url":"https://github.com/andela-atemitope","followers_url":"https://api.github.com/users/andela-atemitope/followers","following_url":"https://api.github.com/users/andela-atemitope/following{/other_user}","gists_url":"https://api.github.com/users/andela-atemitope/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-atemitope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-atemitope/subscriptions","organizations_url":"https://api.github.com/users/andela-atemitope/orgs","repos_url":"https://api.github.com/users/andela-atemitope/repos","events_url":"https://api.github.com/users/andela-atemitope/events{/privacy}","received_events_url":"https://api.github.com/users/andela-atemitope/received_events","type":"User","site_admin":false},"repo":{"id":45042335,"name":"Tushot","full_name":"andela-atemitope/Tushot","owner":{"login":"andela-atemitope","id":13197764,"avatar_url":"https://avatars.githubusercontent.com/u/13197764?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-atemitope","html_url":"https://github.com/andela-atemitope","followers_url":"https://api.github.com/users/andela-atemitope/followers","following_url":"https://api.github.com/users/andela-atemitope/following{/other_user}","gists_url":"https://api.github.com/users/andela-atemitope/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-atemitope/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-atemitope/subscriptions","organizations_url":"https://api.github.com/users/andela-atemitope/orgs","repos_url":"https://api.github.com/users/andela-atemitope/repos","events_url":"https://api.github.com/users/andela-atemitope/events{/privacy}","received_events_url":"https://api.github.com/users/andela-atemitope/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/andela-atemitope/Tushot","description":"A Url Shortener built using Rails 4","fork":false,"url":"https://api.github.com/repos/andela-atemitope/Tushot","forks_url":"https://api.github.com/repos/andela-atemitope/Tushot/forks","keys_url":"https://api.github.com/repos/andela-atemitope/Tushot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela-atemitope/Tushot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela-atemitope/Tushot/teams","hooks_url":"https://api.github.com/repos/andela-atemitope/Tushot/hooks","issue_events_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/events{/number}","events_url":"https://api.github.com/repos/andela-atemitope/Tushot/events","assignees_url":"https://api.github.com/repos/andela-atemitope/Tushot/assignees{/user}","branches_url":"https://api.github.com/repos/andela-atemitope/Tushot/branches{/branch}","tags_url":"https://api.github.com/repos/andela-atemitope/Tushot/tags","blobs_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela-atemitope/Tushot/statuses/{sha}","languages_url":"https://api.github.com/repos/andela-atemitope/Tushot/languages","stargazers_url":"https://api.github.com/repos/andela-atemitope/Tushot/stargazers","contributors_url":"https://api.github.com/repos/andela-atemitope/Tushot/contributors","subscribers_url":"https://api.github.com/repos/andela-atemitope/Tushot/subscribers","subscription_url":"https://api.github.com/repos/andela-atemitope/Tushot/subscription","commits_url":"https://api.github.com/repos/andela-atemitope/Tushot/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela-atemitope/Tushot/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela-atemitope/Tushot/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela-atemitope/Tushot/contents/{+path}","compare_url":"https://api.github.com/repos/andela-atemitope/Tushot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela-atemitope/Tushot/merges","archive_url":"https://api.github.com/repos/andela-atemitope/Tushot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela-atemitope/Tushot/downloads","issues_url":"https://api.github.com/repos/andela-atemitope/Tushot/issues{/number}","pulls_url":"https://api.github.com/repos/andela-atemitope/Tushot/pulls{/number}","milestones_url":"https://api.github.com/repos/andela-atemitope/Tushot/milestones{/number}","notifications_url":"https://api.github.com/repos/andela-atemitope/Tushot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela-atemitope/Tushot/labels{/name}","releases_url":"https://api.github.com/repos/andela-atemitope/Tushot/releases{/id}","created_at":"2015-10-27T13:19:34Z","updated_at":"2015-10-28T10:22:07Z","pushed_at":"2015-10-28T10:29:13Z","git_url":"git://github.com/andela-atemitope/Tushot.git","ssh_url":"git@github.com:andela-atemitope/Tushot.git","clone_url":"https://github.com/andela-atemitope/Tushot.git","svn_url":"https://github.com/andela-atemitope/Tushot","homepage":null,"size":0,"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/andela-atemitope/Tushot/pulls/1"},"html":{"href":"https://github.com/andela-atemitope/Tushot/pull/1"},"issue":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/issues/1"},"comments":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/andela-atemitope/Tushot/statuses/077bc8216293145c37dec1930991cc980526c81d"}}}}