{"action":"created","comment":{"url":"https://api.github.com/repos/andela/anbu-cfh/pulls/comments/93020684","pull_request_review_id":13540618,"id":93020684,"diff_hunk":"@@ -0,0 +1,17 @@\n+\n+angular.module('mean.system')\n+  .factory('LocalStorage', ['localStorageService', function(localStorageService) {\n+    return {\n+      storeToken: function(key, value) {","path":"public/js/services/storage.js","position":5,"original_position":5,"commit_id":"fee52f87f685217eda08ac01621bcb373e00c652","original_commit_id":"fee52f87f685217eda08ac01621bcb373e00c652","user":{"login":"neddinn","id":544570,"avatar_url":"https://avatars.githubusercontent.com/u/544570?v=3","gravatar_id":"","url":"https://api.github.com/users/neddinn","html_url":"https://github.com/neddinn","followers_url":"https://api.github.com/users/neddinn/followers","following_url":"https://api.github.com/users/neddinn/following{/other_user}","gists_url":"https://api.github.com/users/neddinn/gists{/gist_id}","starred_url":"https://api.github.com/users/neddinn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neddinn/subscriptions","organizations_url":"https://api.github.com/users/neddinn/orgs","repos_url":"https://api.github.com/users/neddinn/repos","events_url":"https://api.github.com/users/neddinn/events{/privacy}","received_events_url":"https://api.github.com/users/neddinn/received_events","type":"User","site_admin":false},"body":"Please make the methods here more generic. We dont want to store only token information. You can remove the `Token` from the name","created_at":"2016-12-19T12:16:22Z","updated_at":"2016-12-19T12:16:22Z","html_url":"https://github.com/andela/anbu-cfh/pull/33#discussion_r93020684","pull_request_url":"https://api.github.com/repos/andela/anbu-cfh/pulls/33","_links":{"self":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/comments/93020684"},"html":{"href":"https://github.com/andela/anbu-cfh/pull/33#discussion_r93020684"},"pull_request":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/33"}}},"pull_request":{"url":"https://api.github.com/repos/andela/anbu-cfh/pulls/33","id":98535767,"html_url":"https://github.com/andela/anbu-cfh/pull/33","diff_url":"https://github.com/andela/anbu-cfh/pull/33.diff","patch_url":"https://github.com/andela/anbu-cfh/pull/33.patch","issue_url":"https://api.github.com/repos/andela/anbu-cfh/issues/33","number":33,"state":"open","locked":false,"title":"136024579 create a storage module and angular interceptor","user":{"login":"andela-rakpan","id":23452546,"avatar_url":"https://avatars.githubusercontent.com/u/23452546?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-rakpan","html_url":"https://github.com/andela-rakpan","followers_url":"https://api.github.com/users/andela-rakpan/followers","following_url":"https://api.github.com/users/andela-rakpan/following{/other_user}","gists_url":"https://api.github.com/users/andela-rakpan/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-rakpan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-rakpan/subscriptions","organizations_url":"https://api.github.com/users/andela-rakpan/orgs","repos_url":"https://api.github.com/users/andela-rakpan/repos","events_url":"https://api.github.com/users/andela-rakpan/events{/privacy}","received_events_url":"https://api.github.com/users/andela-rakpan/received_events","type":"User","site_admin":false},"body":"#### What does this PR do?\r\nStores JWT token in local storage upon successful login / signup and uses an interceptor to store token in header requests. \r\n#### Description of Task to be completed?\r\n* Create a storage module to store app-wide information such as tokens.\r\n* Create an angular interceptor that attaches tokens to every http request if available\r\n#### How should this be manually tested?\r\nN/A\r\n#### Any background context you want to provide?\r\nN/A\r\n#### What are the relevant pivotal tracker stories?\r\n#136024489\r\n#136024579\r\n#### Screenshots (if appropriate)\r\nN/A\r\n#### Questions:\r\nN/A","created_at":"2016-12-19T09:57:33Z","updated_at":"2016-12-19T12:16:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f8849de79f892ce2f8c1d24d29a6a7e7fcd1fa3f","assignee":{"login":"neddinn","id":544570,"avatar_url":"https://avatars.githubusercontent.com/u/544570?v=3","gravatar_id":"","url":"https://api.github.com/users/neddinn","html_url":"https://github.com/neddinn","followers_url":"https://api.github.com/users/neddinn/followers","following_url":"https://api.github.com/users/neddinn/following{/other_user}","gists_url":"https://api.github.com/users/neddinn/gists{/gist_id}","starred_url":"https://api.github.com/users/neddinn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neddinn/subscriptions","organizations_url":"https://api.github.com/users/neddinn/orgs","repos_url":"https://api.github.com/users/neddinn/repos","events_url":"https://api.github.com/users/neddinn/events{/privacy}","received_events_url":"https://api.github.com/users/neddinn/received_events","type":"User","site_admin":false},"assignees":[{"login":"neddinn","id":544570,"avatar_url":"https://avatars.githubusercontent.com/u/544570?v=3","gravatar_id":"","url":"https://api.github.com/users/neddinn","html_url":"https://github.com/neddinn","followers_url":"https://api.github.com/users/neddinn/followers","following_url":"https://api.github.com/users/neddinn/following{/other_user}","gists_url":"https://api.github.com/users/neddinn/gists{/gist_id}","starred_url":"https://api.github.com/users/neddinn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neddinn/subscriptions","organizations_url":"https://api.github.com/users/neddinn/orgs","repos_url":"https://api.github.com/users/neddinn/repos","events_url":"https://api.github.com/users/neddinn/events{/privacy}","received_events_url":"https://api.github.com/users/neddinn/received_events","type":"User","site_admin":false},{"login":"andela-venogwe","id":23452630,"avatar_url":"https://avatars.githubusercontent.com/u/23452630?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-venogwe","html_url":"https://github.com/andela-venogwe","followers_url":"https://api.github.com/users/andela-venogwe/followers","following_url":"https://api.github.com/users/andela-venogwe/following{/other_user}","gists_url":"https://api.github.com/users/andela-venogwe/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-venogwe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-venogwe/subscriptions","organizations_url":"https://api.github.com/users/andela-venogwe/orgs","repos_url":"https://api.github.com/users/andela-venogwe/repos","events_url":"https://api.github.com/users/andela-venogwe/events{/privacy}","received_events_url":"https://api.github.com/users/andela-venogwe/received_events","type":"User","site_admin":false},{"login":"andela-oakinseye","id":23452643,"avatar_url":"https://avatars.githubusercontent.com/u/23452643?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-oakinseye","html_url":"https://github.com/andela-oakinseye","followers_url":"https://api.github.com/users/andela-oakinseye/followers","following_url":"https://api.github.com/users/andela-oakinseye/following{/other_user}","gists_url":"https://api.github.com/users/andela-oakinseye/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-oakinseye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-oakinseye/subscriptions","organizations_url":"https://api.github.com/users/andela-oakinseye/orgs","repos_url":"https://api.github.com/users/andela-oakinseye/repos","events_url":"https://api.github.com/users/andela-oakinseye/events{/privacy}","received_events_url":"https://api.github.com/users/andela-oakinseye/received_events","type":"User","site_admin":false},{"login":"andela-aolaniran","id":23452705,"avatar_url":"https://avatars.githubusercontent.com/u/23452705?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-aolaniran","html_url":"https://github.com/andela-aolaniran","followers_url":"https://api.github.com/users/andela-aolaniran/followers","following_url":"https://api.github.com/users/andela-aolaniran/following{/other_user}","gists_url":"https://api.github.com/users/andela-aolaniran/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-aolaniran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-aolaniran/subscriptions","organizations_url":"https://api.github.com/users/andela-aolaniran/orgs","repos_url":"https://api.github.com/users/andela-aolaniran/repos","events_url":"https://api.github.com/users/andela-aolaniran/events{/privacy}","received_events_url":"https://api.github.com/users/andela-aolaniran/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/andela/anbu-cfh/pulls/33/commits","review_comments_url":"https://api.github.com/repos/andela/anbu-cfh/pulls/33/comments","review_comment_url":"https://api.github.com/repos/andela/anbu-cfh/pulls/comments{/number}","comments_url":"https://api.github.com/repos/andela/anbu-cfh/issues/33/comments","statuses_url":"https://api.github.com/repos/andela/anbu-cfh/statuses/fee52f87f685217eda08ac01621bcb373e00c652","head":{"label":"andela:feature/136024579/Create-a-storage-module","ref":"feature/136024579/Create-a-storage-module","sha":"fee52f87f685217eda08ac01621bcb373e00c652","user":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":73683975,"name":"anbu-cfh","full_name":"andela/anbu-cfh","owner":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/anbu-cfh","description":null,"fork":false,"url":"https://api.github.com/repos/andela/anbu-cfh","forks_url":"https://api.github.com/repos/andela/anbu-cfh/forks","keys_url":"https://api.github.com/repos/andela/anbu-cfh/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/anbu-cfh/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/anbu-cfh/teams","hooks_url":"https://api.github.com/repos/andela/anbu-cfh/hooks","issue_events_url":"https://api.github.com/repos/andela/anbu-cfh/issues/events{/number}","events_url":"https://api.github.com/repos/andela/anbu-cfh/events","assignees_url":"https://api.github.com/repos/andela/anbu-cfh/assignees{/user}","branches_url":"https://api.github.com/repos/andela/anbu-cfh/branches{/branch}","tags_url":"https://api.github.com/repos/andela/anbu-cfh/tags","blobs_url":"https://api.github.com/repos/andela/anbu-cfh/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/anbu-cfh/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/anbu-cfh/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/anbu-cfh/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/anbu-cfh/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/anbu-cfh/languages","stargazers_url":"https://api.github.com/repos/andela/anbu-cfh/stargazers","contributors_url":"https://api.github.com/repos/andela/anbu-cfh/contributors","subscribers_url":"https://api.github.com/repos/andela/anbu-cfh/subscribers","subscription_url":"https://api.github.com/repos/andela/anbu-cfh/subscription","commits_url":"https://api.github.com/repos/andela/anbu-cfh/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/anbu-cfh/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/anbu-cfh/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/anbu-cfh/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/anbu-cfh/contents/{+path}","compare_url":"https://api.github.com/repos/andela/anbu-cfh/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/anbu-cfh/merges","archive_url":"https://api.github.com/repos/andela/anbu-cfh/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/anbu-cfh/downloads","issues_url":"https://api.github.com/repos/andela/anbu-cfh/issues{/number}","pulls_url":"https://api.github.com/repos/andela/anbu-cfh/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/anbu-cfh/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/anbu-cfh/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/anbu-cfh/labels{/name}","releases_url":"https://api.github.com/repos/andela/anbu-cfh/releases{/id}","deployments_url":"https://api.github.com/repos/andela/anbu-cfh/deployments","created_at":"2016-11-14T08:36:11Z","updated_at":"2016-11-14T09:29:10Z","pushed_at":"2016-12-19T10:45:49Z","git_url":"git://github.com/andela/anbu-cfh.git","ssh_url":"git@github.com:andela/anbu-cfh.git","clone_url":"https://github.com/andela/anbu-cfh.git","svn_url":"https://github.com/andela/anbu-cfh","homepage":null,"size":12425,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":4,"forks":1,"open_issues":4,"watchers":0,"default_branch":"master"}},"base":{"label":"andela:staging","ref":"staging","sha":"dc3ecc75c2f0d68e7ed87cc8bb0f8d8f099c1541","user":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"repo":{"id":73683975,"name":"anbu-cfh","full_name":"andela/anbu-cfh","owner":{"login":"andela","id":4100206,"avatar_url":"https://avatars.githubusercontent.com/u/4100206?v=3","gravatar_id":"","url":"https://api.github.com/users/andela","html_url":"https://github.com/andela","followers_url":"https://api.github.com/users/andela/followers","following_url":"https://api.github.com/users/andela/following{/other_user}","gists_url":"https://api.github.com/users/andela/gists{/gist_id}","starred_url":"https://api.github.com/users/andela/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela/subscriptions","organizations_url":"https://api.github.com/users/andela/orgs","repos_url":"https://api.github.com/users/andela/repos","events_url":"https://api.github.com/users/andela/events{/privacy}","received_events_url":"https://api.github.com/users/andela/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/andela/anbu-cfh","description":null,"fork":false,"url":"https://api.github.com/repos/andela/anbu-cfh","forks_url":"https://api.github.com/repos/andela/anbu-cfh/forks","keys_url":"https://api.github.com/repos/andela/anbu-cfh/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela/anbu-cfh/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela/anbu-cfh/teams","hooks_url":"https://api.github.com/repos/andela/anbu-cfh/hooks","issue_events_url":"https://api.github.com/repos/andela/anbu-cfh/issues/events{/number}","events_url":"https://api.github.com/repos/andela/anbu-cfh/events","assignees_url":"https://api.github.com/repos/andela/anbu-cfh/assignees{/user}","branches_url":"https://api.github.com/repos/andela/anbu-cfh/branches{/branch}","tags_url":"https://api.github.com/repos/andela/anbu-cfh/tags","blobs_url":"https://api.github.com/repos/andela/anbu-cfh/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela/anbu-cfh/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela/anbu-cfh/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela/anbu-cfh/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela/anbu-cfh/statuses/{sha}","languages_url":"https://api.github.com/repos/andela/anbu-cfh/languages","stargazers_url":"https://api.github.com/repos/andela/anbu-cfh/stargazers","contributors_url":"https://api.github.com/repos/andela/anbu-cfh/contributors","subscribers_url":"https://api.github.com/repos/andela/anbu-cfh/subscribers","subscription_url":"https://api.github.com/repos/andela/anbu-cfh/subscription","commits_url":"https://api.github.com/repos/andela/anbu-cfh/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela/anbu-cfh/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela/anbu-cfh/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela/anbu-cfh/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela/anbu-cfh/contents/{+path}","compare_url":"https://api.github.com/repos/andela/anbu-cfh/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela/anbu-cfh/merges","archive_url":"https://api.github.com/repos/andela/anbu-cfh/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela/anbu-cfh/downloads","issues_url":"https://api.github.com/repos/andela/anbu-cfh/issues{/number}","pulls_url":"https://api.github.com/repos/andela/anbu-cfh/pulls{/number}","milestones_url":"https://api.github.com/repos/andela/anbu-cfh/milestones{/number}","notifications_url":"https://api.github.com/repos/andela/anbu-cfh/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela/anbu-cfh/labels{/name}","releases_url":"https://api.github.com/repos/andela/anbu-cfh/releases{/id}","deployments_url":"https://api.github.com/repos/andela/anbu-cfh/deployments","created_at":"2016-11-14T08:36:11Z","updated_at":"2016-11-14T09:29:10Z","pushed_at":"2016-12-19T10:45:49Z","git_url":"git://github.com/andela/anbu-cfh.git","ssh_url":"git@github.com:andela/anbu-cfh.git","clone_url":"https://github.com/andela/anbu-cfh.git","svn_url":"https://github.com/andela/anbu-cfh","homepage":null,"size":12425,"stargazers_count":0,"watchers_count":0,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":4,"forks":1,"open_issues":4,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/33"},"html":{"href":"https://github.com/andela/anbu-cfh/pull/33"},"issue":{"href":"https://api.github.com/repos/andela/anbu-cfh/issues/33"},"comments":{"href":"https://api.github.com/repos/andela/anbu-cfh/issues/33/comments"},"review_comments":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/33/comments"},"review_comment":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/andela/anbu-cfh/pulls/33/commits"},"statuses":{"href":"https://api.github.com/repos/andela/anbu-cfh/statuses/fee52f87f685217eda08ac01621bcb373e00c652"}}}}
{"actor":{"display_login":"neddinn"}}