{"action":"created","comment":{"url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/comments/176240440","pull_request_review_id":105910188,"id":176240440,"diff_hunk":"@@ -1,62 +1,72 @@\n const DEFAULT_NETWORK_HELPERS = {\n   getToken: () => 'token',\n-  requestGET() {\n+  async requestGET() {\n+    const token = await Promise.resolve(this.getToken && this.getToken())","path":"src/internals/network/getDefaultNetworkHelpers.js","position":5,"original_position":5,"commit_id":"5d4cebb3fe91ea929317d14cc31015b29af9ad15","original_commit_id":"5d4cebb3fe91ea929317d14cc31015b29af9ad15","user":{"login":"mlabrum","id":296106,"avatar_url":"https://avatars2.githubusercontent.com/u/296106?v=4","gravatar_id":"","url":"https://api.github.com/users/mlabrum","html_url":"https://github.com/mlabrum","followers_url":"https://api.github.com/users/mlabrum/followers","following_url":"https://api.github.com/users/mlabrum/following{/other_user}","gists_url":"https://api.github.com/users/mlabrum/gists{/gist_id}","starred_url":"https://api.github.com/users/mlabrum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlabrum/subscriptions","organizations_url":"https://api.github.com/users/mlabrum/orgs","repos_url":"https://api.github.com/users/mlabrum/repos","events_url":"https://api.github.com/users/mlabrum/events{/privacy}","received_events_url":"https://api.github.com/users/mlabrum/received_events","type":"User","site_admin":false},"body":"Hey, good catch I didn't realize that await would turn the value into a promise, I thought it only worked on promises, that's why I had the promise.resolve :D I'll update this","created_at":"2018-03-21T21:14:35Z","updated_at":"2018-03-21T21:14:35Z","html_url":"https://github.com/Brigad/redux-rest-easy/pull/39#discussion_r176240440","pull_request_url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/comments/176240440"},"html":{"href":"https://github.com/Brigad/redux-rest-easy/pull/39#discussion_r176240440"},"pull_request":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39"}},"in_reply_to_id":176005823},"pull_request":{"url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39","id":176378751,"html_url":"https://github.com/Brigad/redux-rest-easy/pull/39","diff_url":"https://github.com/Brigad/redux-rest-easy/pull/39.diff","patch_url":"https://github.com/Brigad/redux-rest-easy/pull/39.patch","issue_url":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/39","number":39,"state":"open","locked":false,"title":"Feature/get token promise support","user":{"login":"mlabrum","id":296106,"avatar_url":"https://avatars2.githubusercontent.com/u/296106?v=4","gravatar_id":"","url":"https://api.github.com/users/mlabrum","html_url":"https://github.com/mlabrum","followers_url":"https://api.github.com/users/mlabrum/followers","following_url":"https://api.github.com/users/mlabrum/following{/other_user}","gists_url":"https://api.github.com/users/mlabrum/gists{/gist_id}","starred_url":"https://api.github.com/users/mlabrum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlabrum/subscriptions","organizations_url":"https://api.github.com/users/mlabrum/orgs","repos_url":"https://api.github.com/users/mlabrum/repos","events_url":"https://api.github.com/users/mlabrum/events{/privacy}","received_events_url":"https://api.github.com/users/mlabrum/received_events","type":"User","site_admin":false},"body":"Hey,\r\n\r\nThanks for this project :D\r\n\r\nThis adds support for promises within `getToken` (if using default network helpers) and `NetworkHelpers` methods are now allowed to return a `Promise`\r\n\r\nI've wrapped the return values of both `getToken` and the network helpers in a `Promise.resolve` to ensure this works in a backwards compatible way as any value returned from them will now be resolved into a promise and `await`ed.\r\n\r\nCheers,","created_at":"2018-03-21T04:09:31Z","updated_at":"2018-03-21T21:14:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f797e83d5ab95e73b98a5dab2fcb7655200fcb15","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39/commits","review_comments_url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39/comments","review_comment_url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/39/comments","statuses_url":"https://api.github.com/repos/Brigad/redux-rest-easy/statuses/5d4cebb3fe91ea929317d14cc31015b29af9ad15","head":{"label":"mlabrum:feature/getTokenPromiseSupport","ref":"feature/getTokenPromiseSupport","sha":"5d4cebb3fe91ea929317d14cc31015b29af9ad15","user":{"login":"mlabrum","id":296106,"avatar_url":"https://avatars2.githubusercontent.com/u/296106?v=4","gravatar_id":"","url":"https://api.github.com/users/mlabrum","html_url":"https://github.com/mlabrum","followers_url":"https://api.github.com/users/mlabrum/followers","following_url":"https://api.github.com/users/mlabrum/following{/other_user}","gists_url":"https://api.github.com/users/mlabrum/gists{/gist_id}","starred_url":"https://api.github.com/users/mlabrum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlabrum/subscriptions","organizations_url":"https://api.github.com/users/mlabrum/orgs","repos_url":"https://api.github.com/users/mlabrum/repos","events_url":"https://api.github.com/users/mlabrum/events{/privacy}","received_events_url":"https://api.github.com/users/mlabrum/received_events","type":"User","site_admin":false},"repo":{"id":126114732,"name":"redux-rest-easy","full_name":"mlabrum/redux-rest-easy","owner":{"login":"mlabrum","id":296106,"avatar_url":"https://avatars2.githubusercontent.com/u/296106?v=4","gravatar_id":"","url":"https://api.github.com/users/mlabrum","html_url":"https://github.com/mlabrum","followers_url":"https://api.github.com/users/mlabrum/followers","following_url":"https://api.github.com/users/mlabrum/following{/other_user}","gists_url":"https://api.github.com/users/mlabrum/gists{/gist_id}","starred_url":"https://api.github.com/users/mlabrum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlabrum/subscriptions","organizations_url":"https://api.github.com/users/mlabrum/orgs","repos_url":"https://api.github.com/users/mlabrum/repos","events_url":"https://api.github.com/users/mlabrum/events{/privacy}","received_events_url":"https://api.github.com/users/mlabrum/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mlabrum/redux-rest-easy","description":"⛳ Redux/React/React Native framework handling network requests, state management, selectors, caching and much more","fork":true,"url":"https://api.github.com/repos/mlabrum/redux-rest-easy","forks_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/forks","keys_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/teams","hooks_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/hooks","issue_events_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/issues/events{/number}","events_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/events","assignees_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/assignees{/user}","branches_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/branches{/branch}","tags_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/tags","blobs_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/git/refs{/sha}","trees_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/statuses/{sha}","languages_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/languages","stargazers_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/stargazers","contributors_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/contributors","subscribers_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/subscribers","subscription_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/subscription","commits_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/commits{/sha}","git_commits_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/git/commits{/sha}","comments_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/comments{/number}","issue_comment_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/issues/comments{/number}","contents_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/contents/{+path}","compare_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/merges","archive_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/downloads","issues_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/issues{/number}","pulls_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/pulls{/number}","milestones_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/milestones{/number}","notifications_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/labels{/name}","releases_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/releases{/id}","deployments_url":"https://api.github.com/repos/mlabrum/redux-rest-easy/deployments","created_at":"2018-03-21T02:57:30Z","updated_at":"2018-03-21T02:57:32Z","pushed_at":"2018-03-21T04:17:25Z","git_url":"git://github.com/mlabrum/redux-rest-easy.git","ssh_url":"git@github.com:mlabrum/redux-rest-easy.git","clone_url":"https://github.com/mlabrum/redux-rest-easy.git","svn_url":"https://github.com/mlabrum/redux-rest-easy","homepage":"","size":212,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Brigad:master","ref":"master","sha":"57c243f87fefdb968d99055bda0655fafb63a0ca","user":{"login":"Brigad","id":16773014,"avatar_url":"https://avatars2.githubusercontent.com/u/16773014?v=4","gravatar_id":"","url":"https://api.github.com/users/Brigad","html_url":"https://github.com/Brigad","followers_url":"https://api.github.com/users/Brigad/followers","following_url":"https://api.github.com/users/Brigad/following{/other_user}","gists_url":"https://api.github.com/users/Brigad/gists{/gist_id}","starred_url":"https://api.github.com/users/Brigad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Brigad/subscriptions","organizations_url":"https://api.github.com/users/Brigad/orgs","repos_url":"https://api.github.com/users/Brigad/repos","events_url":"https://api.github.com/users/Brigad/events{/privacy}","received_events_url":"https://api.github.com/users/Brigad/received_events","type":"Organization","site_admin":false},"repo":{"id":120736197,"name":"redux-rest-easy","full_name":"Brigad/redux-rest-easy","owner":{"login":"Brigad","id":16773014,"avatar_url":"https://avatars2.githubusercontent.com/u/16773014?v=4","gravatar_id":"","url":"https://api.github.com/users/Brigad","html_url":"https://github.com/Brigad","followers_url":"https://api.github.com/users/Brigad/followers","following_url":"https://api.github.com/users/Brigad/following{/other_user}","gists_url":"https://api.github.com/users/Brigad/gists{/gist_id}","starred_url":"https://api.github.com/users/Brigad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Brigad/subscriptions","organizations_url":"https://api.github.com/users/Brigad/orgs","repos_url":"https://api.github.com/users/Brigad/repos","events_url":"https://api.github.com/users/Brigad/events{/privacy}","received_events_url":"https://api.github.com/users/Brigad/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Brigad/redux-rest-easy","description":"⛳ Redux/React/React Native framework handling network requests, state management, selectors, caching and much more","fork":false,"url":"https://api.github.com/repos/Brigad/redux-rest-easy","forks_url":"https://api.github.com/repos/Brigad/redux-rest-easy/forks","keys_url":"https://api.github.com/repos/Brigad/redux-rest-easy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Brigad/redux-rest-easy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Brigad/redux-rest-easy/teams","hooks_url":"https://api.github.com/repos/Brigad/redux-rest-easy/hooks","issue_events_url":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/events{/number}","events_url":"https://api.github.com/repos/Brigad/redux-rest-easy/events","assignees_url":"https://api.github.com/repos/Brigad/redux-rest-easy/assignees{/user}","branches_url":"https://api.github.com/repos/Brigad/redux-rest-easy/branches{/branch}","tags_url":"https://api.github.com/repos/Brigad/redux-rest-easy/tags","blobs_url":"https://api.github.com/repos/Brigad/redux-rest-easy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Brigad/redux-rest-easy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Brigad/redux-rest-easy/git/refs{/sha}","trees_url":"https://api.github.com/repos/Brigad/redux-rest-easy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Brigad/redux-rest-easy/statuses/{sha}","languages_url":"https://api.github.com/repos/Brigad/redux-rest-easy/languages","stargazers_url":"https://api.github.com/repos/Brigad/redux-rest-easy/stargazers","contributors_url":"https://api.github.com/repos/Brigad/redux-rest-easy/contributors","subscribers_url":"https://api.github.com/repos/Brigad/redux-rest-easy/subscribers","subscription_url":"https://api.github.com/repos/Brigad/redux-rest-easy/subscription","commits_url":"https://api.github.com/repos/Brigad/redux-rest-easy/commits{/sha}","git_commits_url":"https://api.github.com/repos/Brigad/redux-rest-easy/git/commits{/sha}","comments_url":"https://api.github.com/repos/Brigad/redux-rest-easy/comments{/number}","issue_comment_url":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/comments{/number}","contents_url":"https://api.github.com/repos/Brigad/redux-rest-easy/contents/{+path}","compare_url":"https://api.github.com/repos/Brigad/redux-rest-easy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Brigad/redux-rest-easy/merges","archive_url":"https://api.github.com/repos/Brigad/redux-rest-easy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Brigad/redux-rest-easy/downloads","issues_url":"https://api.github.com/repos/Brigad/redux-rest-easy/issues{/number}","pulls_url":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls{/number}","milestones_url":"https://api.github.com/repos/Brigad/redux-rest-easy/milestones{/number}","notifications_url":"https://api.github.com/repos/Brigad/redux-rest-easy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Brigad/redux-rest-easy/labels{/name}","releases_url":"https://api.github.com/repos/Brigad/redux-rest-easy/releases{/id}","deployments_url":"https://api.github.com/repos/Brigad/redux-rest-easy/deployments","created_at":"2018-02-08T08:56:29Z","updated_at":"2018-03-21T15:34:28Z","pushed_at":"2018-03-21T15:42:11Z","git_url":"git://github.com/Brigad/redux-rest-easy.git","ssh_url":"git@github.com:Brigad/redux-rest-easy.git","clone_url":"https://github.com/Brigad/redux-rest-easy.git","svn_url":"https://github.com/Brigad/redux-rest-easy","homepage":"","size":183,"stargazers_count":76,"watchers_count":76,"language":"JavaScript","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":3,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":2,"open_issues":3,"watchers":76,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39"},"html":{"href":"https://github.com/Brigad/redux-rest-easy/pull/39"},"issue":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/39"},"comments":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/issues/39/comments"},"review_comments":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39/comments"},"review_comment":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/pulls/39/commits"},"statuses":{"href":"https://api.github.com/repos/Brigad/redux-rest-easy/statuses/5d4cebb3fe91ea929317d14cc31015b29af9ad15"}},"author_association":"NONE"}}
{"actor":{"display_login":"mlabrum"}}