{"action":"created","comment":{"url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/comments/233856909","pull_request_review_id":175367557,"id":233856909,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMzg1NjkwOQ==","diff_hunk":"@@ -2,21 +2,20 @@ const APIClient = require('../../libs/APIClient');\n const Quiz = require('../../libs/Quiz');\n \n class QuizFetcher {\n-  // APIClient.fetchメソッドを使ってクイズデータを取得\n-  APIClient() {\n-    fetch('https://opentdb.com/api.php?amount=10')\n-      .then(response => {\n-        return response.json();\n+  static fetch() {\n+    // 1. APIClient.fetchで問題データ取得\n+    APIClient.fetch('https://opentdb.com/api.php?amount=10')\n+      .then(json => {\n+        return json();\n       });\n   }\n-  //クイズデータをQuizクラスのインスタンスとしてデータを保持\n-  Quiz() {\n-    return [\n-      this.category = category,\n-      this.type = type,\n-      this.difficulty = difficulty,\n-      this.question = question,\n-      this.correctAnswer = correctAnswer,\n-      this.incorrectAnswers = incorrectAnswers];\n-  }\n+  // 2. 1で取得した問題データを使ってQuizクラスのインスタンス生成\n+","path":"libs/QuizFetcher.js","position":13,"original_position":27,"commit_id":"d94d903806cf2e76f951d0d1375bd3b9889ce0d5","original_commit_id":"d94d903806cf2e76f951d0d1375bd3b9889ce0d5","user":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"body":"  // 2. 1で取得した問題データを使ってQuizクラスのインスタンス生成\r\nの部分の実装方法が分からないです。","created_at":"2018-11-15T14:15:54Z","updated_at":"2018-11-15T14:15:58Z","html_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5#discussion_r233856909","pull_request_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/comments/233856909"},"html":{"href":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5#discussion_r233856909"},"pull_request":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5","id":230846825,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMwODQ2ODI1","html_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5","diff_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5.diff","patch_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5.patch","issue_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/5","number":5,"state":"open","locked":false,"title":"Feature/impl quiz fetcher class","user":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"body":"QuizFetcherクラスの実装","created_at":"2018-11-14T14:05:28Z","updated_at":"2018-11-15T14:15:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bc271feae89fc8da9da2731a85bf89507b1e0950","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5/commits","review_comments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5/comments","review_comment_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/comments{/number}","comments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/5/comments","statuses_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/statuses/d94d903806cf2e76f951d0d1375bd3b9889ce0d5","head":{"label":"y-akamatsu:feature/impl-quiz-fetcher-class","ref":"feature/impl-quiz-fetcher-class","sha":"d94d903806cf2e76f951d0d1375bd3b9889ce0d5","user":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"repo":{"id":155075710,"node_id":"MDEwOlJlcG9zaXRvcnkxNTUwNzU3MTA=","name":"AkamatsuTrivialQuiz-API","full_name":"y-akamatsu/AkamatsuTrivialQuiz-API","private":false,"owner":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"html_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API","description":null,"fork":false,"url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API","forks_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/forks","keys_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/keys{/key_id}","collaborators_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/teams","hooks_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/hooks","issue_events_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/events{/number}","events_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/events","assignees_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/assignees{/user}","branches_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/branches{/branch}","tags_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/tags","blobs_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/refs{/sha}","trees_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/trees{/sha}","statuses_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/statuses/{sha}","languages_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/languages","stargazers_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/stargazers","contributors_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/contributors","subscribers_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/subscribers","subscription_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/subscription","commits_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/commits{/sha}","git_commits_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/commits{/sha}","comments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/comments{/number}","issue_comment_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/comments{/number}","contents_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/contents/{+path}","compare_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/compare/{base}...{head}","merges_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/merges","archive_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/downloads","issues_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues{/number}","pulls_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls{/number}","milestones_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/milestones{/number}","notifications_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/labels{/name}","releases_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/releases{/id}","deployments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/deployments","created_at":"2018-10-28T13:45:27Z","updated_at":"2018-10-28T13:53:28Z","pushed_at":"2018-11-15T13:59:37Z","git_url":"git://github.com/y-akamatsu/AkamatsuTrivialQuiz-API.git","ssh_url":"git@github.com:y-akamatsu/AkamatsuTrivialQuiz-API.git","clone_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API.git","svn_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API","homepage":null,"size":665,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"y-akamatsu:develop","ref":"develop","sha":"613dbae2a2b55960df06a19289de48b78f130505","user":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"repo":{"id":155075710,"node_id":"MDEwOlJlcG9zaXRvcnkxNTUwNzU3MTA=","name":"AkamatsuTrivialQuiz-API","full_name":"y-akamatsu/AkamatsuTrivialQuiz-API","private":false,"owner":{"login":"y-akamatsu","id":37663570,"node_id":"MDQ6VXNlcjM3NjYzNTcw","avatar_url":"https://avatars2.githubusercontent.com/u/37663570?v=4","gravatar_id":"","url":"https://api.github.com/users/y-akamatsu","html_url":"https://github.com/y-akamatsu","followers_url":"https://api.github.com/users/y-akamatsu/followers","following_url":"https://api.github.com/users/y-akamatsu/following{/other_user}","gists_url":"https://api.github.com/users/y-akamatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/y-akamatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/y-akamatsu/subscriptions","organizations_url":"https://api.github.com/users/y-akamatsu/orgs","repos_url":"https://api.github.com/users/y-akamatsu/repos","events_url":"https://api.github.com/users/y-akamatsu/events{/privacy}","received_events_url":"https://api.github.com/users/y-akamatsu/received_events","type":"User","site_admin":false},"html_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API","description":null,"fork":false,"url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API","forks_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/forks","keys_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/keys{/key_id}","collaborators_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/teams","hooks_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/hooks","issue_events_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/events{/number}","events_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/events","assignees_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/assignees{/user}","branches_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/branches{/branch}","tags_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/tags","blobs_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/refs{/sha}","trees_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/trees{/sha}","statuses_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/statuses/{sha}","languages_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/languages","stargazers_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/stargazers","contributors_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/contributors","subscribers_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/subscribers","subscription_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/subscription","commits_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/commits{/sha}","git_commits_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/git/commits{/sha}","comments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/comments{/number}","issue_comment_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/comments{/number}","contents_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/contents/{+path}","compare_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/compare/{base}...{head}","merges_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/merges","archive_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/downloads","issues_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues{/number}","pulls_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls{/number}","milestones_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/milestones{/number}","notifications_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/labels{/name}","releases_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/releases{/id}","deployments_url":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/deployments","created_at":"2018-10-28T13:45:27Z","updated_at":"2018-10-28T13:53:28Z","pushed_at":"2018-11-15T13:59:37Z","git_url":"git://github.com/y-akamatsu/AkamatsuTrivialQuiz-API.git","ssh_url":"git@github.com:y-akamatsu/AkamatsuTrivialQuiz-API.git","clone_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API.git","svn_url":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API","homepage":null,"size":665,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5"},"html":{"href":"https://github.com/y-akamatsu/AkamatsuTrivialQuiz-API/pull/5"},"issue":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/5"},"comments":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/y-akamatsu/AkamatsuTrivialQuiz-API/statuses/d94d903806cf2e76f951d0d1375bd3b9889ce0d5"}},"author_association":"OWNER"}}
{"actor":{"display_login":"y-akamatsu"}}