{"action":"created","comment":{"url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/comments/23120745","id":23120745,"diff_hunk":"@@ -0,0 +1,190 @@\n+\n+/**\n+ * Module dependencies.\n+ */\n+\n+import angular from 'angular';\n+import queryString from 'query-string';\n+\n+var defaults = {\n+  baseUrl: null,\n+  clientId: null,\n+  clientSecret: null,\n+  grantPath: '/oauth2/token',\n+  revokePath: '/oauth2/revoke'\n+};\n+\n+/**\n+ * OAuth provider.\n+ */\n+\n+function OAuthProvider() {\n+  var config;\n+\n+  /**\n+   * Configure.\n+   *\n+   * @param {object} params - An `object` of params to extend.\n+   */\n+\n+  this.configure = function(params) {\n+    // Can only be configured once.\n+    if (config) {\n+      throw new Error('Already configured.');\n+    }\n+\n+    // Check if is an `object`.\n+    if (params instanceof Object) {","path":"src/providers/oauth-provider.js","position":37,"original_position":37,"commit_id":"8b2fd442acf508e7f6c954d944a8db6a28a2ca16","original_commit_id":"8b2fd442acf508e7f6c954d944a8db6a28a2ca16","user":{"login":"fixe","id":484559,"avatar_url":"https://avatars.githubusercontent.com/u/484559?v=3","gravatar_id":"","url":"https://api.github.com/users/fixe","html_url":"https://github.com/fixe","followers_url":"https://api.github.com/users/fixe/followers","following_url":"https://api.github.com/users/fixe/following{/other_user}","gists_url":"https://api.github.com/users/fixe/gists{/gist_id}","starred_url":"https://api.github.com/users/fixe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fixe/subscriptions","organizations_url":"https://api.github.com/users/fixe/orgs","repos_url":"https://api.github.com/users/fixe/repos","events_url":"https://api.github.com/users/fixe/events{/privacy}","received_events_url":"https://api.github.com/users/fixe/received_events","type":"User","site_admin":false},"body":"`if !params instance of`, throw.","created_at":"2015-01-17T01:27:16Z","updated_at":"2015-01-17T01:27:16Z","html_url":"https://github.com/seegno/angular-oauth2/pull/1#discussion_r23120745","pull_request_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/seegno/angular-oauth2/pulls/comments/23120745"},"html":{"href":"https://github.com/seegno/angular-oauth2/pull/1#discussion_r23120745"},"pull_request":{"href":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1","id":27546715,"html_url":"https://github.com/seegno/angular-oauth2/pull/1","diff_url":"https://github.com/seegno/angular-oauth2/pull/1.diff","patch_url":"https://github.com/seegno/angular-oauth2/pull/1.patch","issue_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/1","number":1,"state":"open","locked":false,"title":"[WIP] Add project structure","user":{"login":"ruipenso","id":73298,"avatar_url":"https://avatars.githubusercontent.com/u/73298?v=3","gravatar_id":"","url":"https://api.github.com/users/ruipenso","html_url":"https://github.com/ruipenso","followers_url":"https://api.github.com/users/ruipenso/followers","following_url":"https://api.github.com/users/ruipenso/following{/other_user}","gists_url":"https://api.github.com/users/ruipenso/gists{/gist_id}","starred_url":"https://api.github.com/users/ruipenso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruipenso/subscriptions","organizations_url":"https://api.github.com/users/ruipenso/orgs","repos_url":"https://api.github.com/users/ruipenso/repos","events_url":"https://api.github.com/users/ruipenso/events{/privacy}","received_events_url":"https://api.github.com/users/ruipenso/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-01-17T00:08:26Z","updated_at":"2015-01-17T01:27:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4509d77c59deab62a33e4b493b33defe6ff03c5b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1/commits","review_comments_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1/comments","review_comment_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls/comments/{number}","comments_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/1/comments","statuses_url":"https://api.github.com/repos/seegno/angular-oauth2/statuses/8b2fd442acf508e7f6c954d944a8db6a28a2ca16","head":{"label":"seegno:feature/add-project-structure","ref":"feature/add-project-structure","sha":"8b2fd442acf508e7f6c954d944a8db6a28a2ca16","user":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"repo":{"id":29157050,"name":"angular-oauth2","full_name":"seegno/angular-oauth2","owner":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seegno/angular-oauth2","description":"AngularJS OAuth2","fork":false,"url":"https://api.github.com/repos/seegno/angular-oauth2","forks_url":"https://api.github.com/repos/seegno/angular-oauth2/forks","keys_url":"https://api.github.com/repos/seegno/angular-oauth2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seegno/angular-oauth2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seegno/angular-oauth2/teams","hooks_url":"https://api.github.com/repos/seegno/angular-oauth2/hooks","issue_events_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/events{/number}","events_url":"https://api.github.com/repos/seegno/angular-oauth2/events","assignees_url":"https://api.github.com/repos/seegno/angular-oauth2/assignees{/user}","branches_url":"https://api.github.com/repos/seegno/angular-oauth2/branches{/branch}","tags_url":"https://api.github.com/repos/seegno/angular-oauth2/tags","blobs_url":"https://api.github.com/repos/seegno/angular-oauth2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seegno/angular-oauth2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seegno/angular-oauth2/git/refs{/sha}","trees_url":"https://api.github.com/repos/seegno/angular-oauth2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seegno/angular-oauth2/statuses/{sha}","languages_url":"https://api.github.com/repos/seegno/angular-oauth2/languages","stargazers_url":"https://api.github.com/repos/seegno/angular-oauth2/stargazers","contributors_url":"https://api.github.com/repos/seegno/angular-oauth2/contributors","subscribers_url":"https://api.github.com/repos/seegno/angular-oauth2/subscribers","subscription_url":"https://api.github.com/repos/seegno/angular-oauth2/subscription","commits_url":"https://api.github.com/repos/seegno/angular-oauth2/commits{/sha}","git_commits_url":"https://api.github.com/repos/seegno/angular-oauth2/git/commits{/sha}","comments_url":"https://api.github.com/repos/seegno/angular-oauth2/comments{/number}","issue_comment_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/comments/{number}","contents_url":"https://api.github.com/repos/seegno/angular-oauth2/contents/{+path}","compare_url":"https://api.github.com/repos/seegno/angular-oauth2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seegno/angular-oauth2/merges","archive_url":"https://api.github.com/repos/seegno/angular-oauth2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seegno/angular-oauth2/downloads","issues_url":"https://api.github.com/repos/seegno/angular-oauth2/issues{/number}","pulls_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls{/number}","milestones_url":"https://api.github.com/repos/seegno/angular-oauth2/milestones{/number}","notifications_url":"https://api.github.com/repos/seegno/angular-oauth2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seegno/angular-oauth2/labels{/name}","releases_url":"https://api.github.com/repos/seegno/angular-oauth2/releases{/id}","created_at":"2015-01-12T21:09:21Z","updated_at":"2015-01-17T01:12:16Z","pushed_at":"2015-01-17T00:17:58Z","git_url":"git://github.com/seegno/angular-oauth2.git","ssh_url":"git@github.com:seegno/angular-oauth2.git","clone_url":"https://github.com/seegno/angular-oauth2.git","svn_url":"https://github.com/seegno/angular-oauth2","homepage":"http://seegno.com","size":0,"stargazers_count":0,"watchers_count":0,"language":null,"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":"seegno:master","ref":"master","sha":"f8882f85ebfbfb17fff5e92a3dac2a56a7c038d7","user":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"repo":{"id":29157050,"name":"angular-oauth2","full_name":"seegno/angular-oauth2","owner":{"login":"seegno","id":1326469,"avatar_url":"https://avatars.githubusercontent.com/u/1326469?v=3","gravatar_id":"","url":"https://api.github.com/users/seegno","html_url":"https://github.com/seegno","followers_url":"https://api.github.com/users/seegno/followers","following_url":"https://api.github.com/users/seegno/following{/other_user}","gists_url":"https://api.github.com/users/seegno/gists{/gist_id}","starred_url":"https://api.github.com/users/seegno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seegno/subscriptions","organizations_url":"https://api.github.com/users/seegno/orgs","repos_url":"https://api.github.com/users/seegno/repos","events_url":"https://api.github.com/users/seegno/events{/privacy}","received_events_url":"https://api.github.com/users/seegno/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seegno/angular-oauth2","description":"AngularJS OAuth2","fork":false,"url":"https://api.github.com/repos/seegno/angular-oauth2","forks_url":"https://api.github.com/repos/seegno/angular-oauth2/forks","keys_url":"https://api.github.com/repos/seegno/angular-oauth2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seegno/angular-oauth2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seegno/angular-oauth2/teams","hooks_url":"https://api.github.com/repos/seegno/angular-oauth2/hooks","issue_events_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/events{/number}","events_url":"https://api.github.com/repos/seegno/angular-oauth2/events","assignees_url":"https://api.github.com/repos/seegno/angular-oauth2/assignees{/user}","branches_url":"https://api.github.com/repos/seegno/angular-oauth2/branches{/branch}","tags_url":"https://api.github.com/repos/seegno/angular-oauth2/tags","blobs_url":"https://api.github.com/repos/seegno/angular-oauth2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seegno/angular-oauth2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seegno/angular-oauth2/git/refs{/sha}","trees_url":"https://api.github.com/repos/seegno/angular-oauth2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seegno/angular-oauth2/statuses/{sha}","languages_url":"https://api.github.com/repos/seegno/angular-oauth2/languages","stargazers_url":"https://api.github.com/repos/seegno/angular-oauth2/stargazers","contributors_url":"https://api.github.com/repos/seegno/angular-oauth2/contributors","subscribers_url":"https://api.github.com/repos/seegno/angular-oauth2/subscribers","subscription_url":"https://api.github.com/repos/seegno/angular-oauth2/subscription","commits_url":"https://api.github.com/repos/seegno/angular-oauth2/commits{/sha}","git_commits_url":"https://api.github.com/repos/seegno/angular-oauth2/git/commits{/sha}","comments_url":"https://api.github.com/repos/seegno/angular-oauth2/comments{/number}","issue_comment_url":"https://api.github.com/repos/seegno/angular-oauth2/issues/comments/{number}","contents_url":"https://api.github.com/repos/seegno/angular-oauth2/contents/{+path}","compare_url":"https://api.github.com/repos/seegno/angular-oauth2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seegno/angular-oauth2/merges","archive_url":"https://api.github.com/repos/seegno/angular-oauth2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seegno/angular-oauth2/downloads","issues_url":"https://api.github.com/repos/seegno/angular-oauth2/issues{/number}","pulls_url":"https://api.github.com/repos/seegno/angular-oauth2/pulls{/number}","milestones_url":"https://api.github.com/repos/seegno/angular-oauth2/milestones{/number}","notifications_url":"https://api.github.com/repos/seegno/angular-oauth2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seegno/angular-oauth2/labels{/name}","releases_url":"https://api.github.com/repos/seegno/angular-oauth2/releases{/id}","created_at":"2015-01-12T21:09:21Z","updated_at":"2015-01-17T01:12:16Z","pushed_at":"2015-01-17T00:17:58Z","git_url":"git://github.com/seegno/angular-oauth2.git","ssh_url":"git@github.com:seegno/angular-oauth2.git","clone_url":"https://github.com/seegno/angular-oauth2.git","svn_url":"https://github.com/seegno/angular-oauth2","homepage":"http://seegno.com","size":0,"stargazers_count":0,"watchers_count":0,"language":null,"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/seegno/angular-oauth2/pulls/1"},"html":{"href":"https://github.com/seegno/angular-oauth2/pull/1"},"issue":{"href":"https://api.github.com/repos/seegno/angular-oauth2/issues/1"},"comments":{"href":"https://api.github.com/repos/seegno/angular-oauth2/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/seegno/angular-oauth2/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/seegno/angular-oauth2/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/seegno/angular-oauth2/statuses/8b2fd442acf508e7f6c954d944a8db6a28a2ca16"}}}}