{"action":"created","comment":{"url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/comments/28813954","id":28813954,"diff_hunk":"@@ -1,5 +1,20 @@\n class User < ActiveRecord::Base\n \thas_secure_password\n \n-\tvalidates :user_name, presence: true, uniqueness: true\n+\tvalidates :user_name, presence: true\n+\n+\tdef self.find_or_create_from_auth(data)\n+  \tuser = User.find_or_create_by(provider: data.provider, uid: data.uid)\n+      \n+      user.provider = auth.provider","path":"app/models/user.rb","position":10,"original_position":10,"commit_id":"f595ab8840e51a34527409be0b34a6de881ebf79","original_commit_id":"f595ab8840e51a34527409be0b34a6de881ebf79","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":"Inconsistent indentation detected.","created_at":"2015-04-21T19:35:43Z","updated_at":"2015-04-21T19:35:43Z","html_url":"https://github.com/mirjoy/meal_planning_app/pull/7#discussion_r28813954","pull_request_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/comments/28813954"},"html":{"href":"https://github.com/mirjoy/meal_planning_app/pull/7#discussion_r28813954"},"pull_request":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7","id":33795355,"html_url":"https://github.com/mirjoy/meal_planning_app/pull/7","diff_url":"https://github.com/mirjoy/meal_planning_app/pull/7.diff","patch_url":"https://github.com/mirjoy/meal_planning_app/pull/7.patch","issue_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/7","number":7,"state":"open","locked":false,"title":"Facebook auth","user":{"login":"mirjoy","id":5142805,"avatar_url":"https://avatars.githubusercontent.com/u/5142805?v=3","gravatar_id":"","url":"https://api.github.com/users/mirjoy","html_url":"https://github.com/mirjoy","followers_url":"https://api.github.com/users/mirjoy/followers","following_url":"https://api.github.com/users/mirjoy/following{/other_user}","gists_url":"https://api.github.com/users/mirjoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mirjoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirjoy/subscriptions","organizations_url":"https://api.github.com/users/mirjoy/orgs","repos_url":"https://api.github.com/users/mirjoy/repos","events_url":"https://api.github.com/users/mirjoy/events{/privacy}","received_events_url":"https://api.github.com/users/mirjoy/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-04-21T19:35:38Z","updated_at":"2015-04-21T19:35:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8ec04c7d42944e650d77754d7e119ec7c78aa3a0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7/commits","review_comments_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7/comments","review_comment_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/7/comments","statuses_url":"https://api.github.com/repos/mirjoy/meal_planning_app/statuses/f595ab8840e51a34527409be0b34a6de881ebf79","head":{"label":"mirjoy:facebook-auth","ref":"facebook-auth","sha":"f595ab8840e51a34527409be0b34a6de881ebf79","user":{"login":"mirjoy","id":5142805,"avatar_url":"https://avatars.githubusercontent.com/u/5142805?v=3","gravatar_id":"","url":"https://api.github.com/users/mirjoy","html_url":"https://github.com/mirjoy","followers_url":"https://api.github.com/users/mirjoy/followers","following_url":"https://api.github.com/users/mirjoy/following{/other_user}","gists_url":"https://api.github.com/users/mirjoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mirjoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirjoy/subscriptions","organizations_url":"https://api.github.com/users/mirjoy/orgs","repos_url":"https://api.github.com/users/mirjoy/repos","events_url":"https://api.github.com/users/mirjoy/events{/privacy}","received_events_url":"https://api.github.com/users/mirjoy/received_events","type":"User","site_admin":false},"repo":{"id":34230061,"name":"meal_planning_app","full_name":"mirjoy/meal_planning_app","owner":{"login":"mirjoy","id":5142805,"avatar_url":"https://avatars.githubusercontent.com/u/5142805?v=3","gravatar_id":"","url":"https://api.github.com/users/mirjoy","html_url":"https://github.com/mirjoy","followers_url":"https://api.github.com/users/mirjoy/followers","following_url":"https://api.github.com/users/mirjoy/following{/other_user}","gists_url":"https://api.github.com/users/mirjoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mirjoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirjoy/subscriptions","organizations_url":"https://api.github.com/users/mirjoy/orgs","repos_url":"https://api.github.com/users/mirjoy/repos","events_url":"https://api.github.com/users/mirjoy/events{/privacy}","received_events_url":"https://api.github.com/users/mirjoy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mirjoy/meal_planning_app","description":"An individual project that consumes a recipe API, allows users to input their dietary preferences, and then generates meal plans and grocery lists.","fork":false,"url":"https://api.github.com/repos/mirjoy/meal_planning_app","forks_url":"https://api.github.com/repos/mirjoy/meal_planning_app/forks","keys_url":"https://api.github.com/repos/mirjoy/meal_planning_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mirjoy/meal_planning_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mirjoy/meal_planning_app/teams","hooks_url":"https://api.github.com/repos/mirjoy/meal_planning_app/hooks","issue_events_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/events{/number}","events_url":"https://api.github.com/repos/mirjoy/meal_planning_app/events","assignees_url":"https://api.github.com/repos/mirjoy/meal_planning_app/assignees{/user}","branches_url":"https://api.github.com/repos/mirjoy/meal_planning_app/branches{/branch}","tags_url":"https://api.github.com/repos/mirjoy/meal_planning_app/tags","blobs_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mirjoy/meal_planning_app/statuses/{sha}","languages_url":"https://api.github.com/repos/mirjoy/meal_planning_app/languages","stargazers_url":"https://api.github.com/repos/mirjoy/meal_planning_app/stargazers","contributors_url":"https://api.github.com/repos/mirjoy/meal_planning_app/contributors","subscribers_url":"https://api.github.com/repos/mirjoy/meal_planning_app/subscribers","subscription_url":"https://api.github.com/repos/mirjoy/meal_planning_app/subscription","commits_url":"https://api.github.com/repos/mirjoy/meal_planning_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/mirjoy/meal_planning_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/mirjoy/meal_planning_app/contents/{+path}","compare_url":"https://api.github.com/repos/mirjoy/meal_planning_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mirjoy/meal_planning_app/merges","archive_url":"https://api.github.com/repos/mirjoy/meal_planning_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mirjoy/meal_planning_app/downloads","issues_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues{/number}","pulls_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls{/number}","milestones_url":"https://api.github.com/repos/mirjoy/meal_planning_app/milestones{/number}","notifications_url":"https://api.github.com/repos/mirjoy/meal_planning_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mirjoy/meal_planning_app/labels{/name}","releases_url":"https://api.github.com/repos/mirjoy/meal_planning_app/releases{/id}","created_at":"2015-04-20T00:36:44Z","updated_at":"2015-04-21T19:21:31Z","pushed_at":"2015-04-21T19:35:39Z","git_url":"git://github.com/mirjoy/meal_planning_app.git","ssh_url":"git@github.com:mirjoy/meal_planning_app.git","clone_url":"https://github.com/mirjoy/meal_planning_app.git","svn_url":"https://github.com/mirjoy/meal_planning_app","homepage":"http://delistcious.herokuapp.com/","size":0,"stargazers_count":0,"watchers_count":0,"language":"CSS","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":"mirjoy:master","ref":"master","sha":"8c772dcdf5b73cc78bced8b2aa8df42738edd306","user":{"login":"mirjoy","id":5142805,"avatar_url":"https://avatars.githubusercontent.com/u/5142805?v=3","gravatar_id":"","url":"https://api.github.com/users/mirjoy","html_url":"https://github.com/mirjoy","followers_url":"https://api.github.com/users/mirjoy/followers","following_url":"https://api.github.com/users/mirjoy/following{/other_user}","gists_url":"https://api.github.com/users/mirjoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mirjoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirjoy/subscriptions","organizations_url":"https://api.github.com/users/mirjoy/orgs","repos_url":"https://api.github.com/users/mirjoy/repos","events_url":"https://api.github.com/users/mirjoy/events{/privacy}","received_events_url":"https://api.github.com/users/mirjoy/received_events","type":"User","site_admin":false},"repo":{"id":34230061,"name":"meal_planning_app","full_name":"mirjoy/meal_planning_app","owner":{"login":"mirjoy","id":5142805,"avatar_url":"https://avatars.githubusercontent.com/u/5142805?v=3","gravatar_id":"","url":"https://api.github.com/users/mirjoy","html_url":"https://github.com/mirjoy","followers_url":"https://api.github.com/users/mirjoy/followers","following_url":"https://api.github.com/users/mirjoy/following{/other_user}","gists_url":"https://api.github.com/users/mirjoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mirjoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mirjoy/subscriptions","organizations_url":"https://api.github.com/users/mirjoy/orgs","repos_url":"https://api.github.com/users/mirjoy/repos","events_url":"https://api.github.com/users/mirjoy/events{/privacy}","received_events_url":"https://api.github.com/users/mirjoy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mirjoy/meal_planning_app","description":"An individual project that consumes a recipe API, allows users to input their dietary preferences, and then generates meal plans and grocery lists.","fork":false,"url":"https://api.github.com/repos/mirjoy/meal_planning_app","forks_url":"https://api.github.com/repos/mirjoy/meal_planning_app/forks","keys_url":"https://api.github.com/repos/mirjoy/meal_planning_app/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mirjoy/meal_planning_app/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mirjoy/meal_planning_app/teams","hooks_url":"https://api.github.com/repos/mirjoy/meal_planning_app/hooks","issue_events_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/events{/number}","events_url":"https://api.github.com/repos/mirjoy/meal_planning_app/events","assignees_url":"https://api.github.com/repos/mirjoy/meal_planning_app/assignees{/user}","branches_url":"https://api.github.com/repos/mirjoy/meal_planning_app/branches{/branch}","tags_url":"https://api.github.com/repos/mirjoy/meal_planning_app/tags","blobs_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/refs{/sha}","trees_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mirjoy/meal_planning_app/statuses/{sha}","languages_url":"https://api.github.com/repos/mirjoy/meal_planning_app/languages","stargazers_url":"https://api.github.com/repos/mirjoy/meal_planning_app/stargazers","contributors_url":"https://api.github.com/repos/mirjoy/meal_planning_app/contributors","subscribers_url":"https://api.github.com/repos/mirjoy/meal_planning_app/subscribers","subscription_url":"https://api.github.com/repos/mirjoy/meal_planning_app/subscription","commits_url":"https://api.github.com/repos/mirjoy/meal_planning_app/commits{/sha}","git_commits_url":"https://api.github.com/repos/mirjoy/meal_planning_app/git/commits{/sha}","comments_url":"https://api.github.com/repos/mirjoy/meal_planning_app/comments{/number}","issue_comment_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/comments{/number}","contents_url":"https://api.github.com/repos/mirjoy/meal_planning_app/contents/{+path}","compare_url":"https://api.github.com/repos/mirjoy/meal_planning_app/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mirjoy/meal_planning_app/merges","archive_url":"https://api.github.com/repos/mirjoy/meal_planning_app/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mirjoy/meal_planning_app/downloads","issues_url":"https://api.github.com/repos/mirjoy/meal_planning_app/issues{/number}","pulls_url":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls{/number}","milestones_url":"https://api.github.com/repos/mirjoy/meal_planning_app/milestones{/number}","notifications_url":"https://api.github.com/repos/mirjoy/meal_planning_app/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mirjoy/meal_planning_app/labels{/name}","releases_url":"https://api.github.com/repos/mirjoy/meal_planning_app/releases{/id}","created_at":"2015-04-20T00:36:44Z","updated_at":"2015-04-21T19:21:31Z","pushed_at":"2015-04-21T19:35:39Z","git_url":"git://github.com/mirjoy/meal_planning_app.git","ssh_url":"git@github.com:mirjoy/meal_planning_app.git","clone_url":"https://github.com/mirjoy/meal_planning_app.git","svn_url":"https://github.com/mirjoy/meal_planning_app","homepage":"http://delistcious.herokuapp.com/","size":0,"stargazers_count":0,"watchers_count":0,"language":"CSS","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/mirjoy/meal_planning_app/pulls/7"},"html":{"href":"https://github.com/mirjoy/meal_planning_app/pull/7"},"issue":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/7"},"comments":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/mirjoy/meal_planning_app/statuses/f595ab8840e51a34527409be0b34a6de881ebf79"}}}}