{"action":"created","comment":{"url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/comments/60859339","id":60859339,"diff_hunk":"@@ -83,3 +83,31 @@ export async function requestDeleteItemToFavList(data = {\n     return () => {};\n   }\n }\n+\n+// ------------------------------------------------------------------ ask a item\n+export async function requestAskItem(data = {\n+  id: '',\n+}) {\n+  const favoriteApi = `/rest/favorite/${data.id}`;\n+  try {\n+    const response = await fetchWithAuth(favoriteApi, 'DELETE');\n+\n+    let postList = [];\n+    postList = [...data.postList];\n+\n+    if (response.result) {\n+      // Alert.alert('result', '刪除我的最愛成功!');\n+      postList = findItemById(data.id, postList, false);","path":"app/actions/PostDetailActions.js","position":18,"original_position":18,"commit_id":"c14317bbaa439c3f4374fb3af7f895cd62ef857e","original_commit_id":"449ce418f7c2e4aa65221610561819be44c14cd5","user":{"login":"smlsunxie","id":1689227,"avatar_url":"https://avatars.githubusercontent.com/u/1689227?v=3","gravatar_id":"","url":"https://api.github.com/users/smlsunxie","html_url":"https://github.com/smlsunxie","followers_url":"https://api.github.com/users/smlsunxie/followers","following_url":"https://api.github.com/users/smlsunxie/following{/other_user}","gists_url":"https://api.github.com/users/smlsunxie/gists{/gist_id}","starred_url":"https://api.github.com/users/smlsunxie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smlsunxie/subscriptions","organizations_url":"https://api.github.com/users/smlsunxie/orgs","repos_url":"https://api.github.com/users/smlsunxie/repos","events_url":"https://api.github.com/users/smlsunxie/events{/privacy}","received_events_url":"https://api.github.com/users/smlsunxie/received_events","type":"User","site_admin":false},"body":"若是 findItemById 應該有前面兩個參數，設定 isFav 應該要由另外一個函式來處理\r\n\r\n不然，會很容易混淆，從函式名稱沒有辦法聯想到最後一個參數是要變動 我的最愛 的狀態","created_at":"2016-04-25T03:05:20Z","updated_at":"2016-04-25T03:05:20Z","html_url":"https://github.com/trunk-studio/trademuch-native/pull/214#discussion_r60859339","pull_request_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214","_links":{"self":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/comments/60859339"},"html":{"href":"https://github.com/trunk-studio/trademuch-native/pull/214#discussion_r60859339"},"pull_request":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214"}}},"pull_request":{"url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214","id":67467255,"html_url":"https://github.com/trunk-studio/trademuch-native/pull/214","diff_url":"https://github.com/trunk-studio/trademuch-native/pull/214.diff","patch_url":"https://github.com/trunk-studio/trademuch-native/pull/214.patch","issue_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/214","number":214,"state":"open","locked":false,"title":"connect givepage and apis","user":{"login":"kuyen","id":1522808,"avatar_url":"https://avatars.githubusercontent.com/u/1522808?v=3","gravatar_id":"","url":"https://api.github.com/users/kuyen","html_url":"https://github.com/kuyen","followers_url":"https://api.github.com/users/kuyen/followers","following_url":"https://api.github.com/users/kuyen/following{/other_user}","gists_url":"https://api.github.com/users/kuyen/gists{/gist_id}","starred_url":"https://api.github.com/users/kuyen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kuyen/subscriptions","organizations_url":"https://api.github.com/users/kuyen/orgs","repos_url":"https://api.github.com/users/kuyen/repos","events_url":"https://api.github.com/users/kuyen/events{/privacy}","received_events_url":"https://api.github.com/users/kuyen/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-04-22T06:59:01Z","updated_at":"2016-04-25T03:05:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5fe0b8d912559d091e0a43f392f5738af57c231e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214/commits","review_comments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214/comments","review_comment_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/comments{/number}","comments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/214/comments","statuses_url":"https://api.github.com/repos/trunk-studio/trademuch-native/statuses/c14317bbaa439c3f4374fb3af7f895cd62ef857e","head":{"label":"trunk-studio:feature/connectGivePage","ref":"feature/connectGivePage","sha":"c14317bbaa439c3f4374fb3af7f895cd62ef857e","user":{"login":"trunk-studio","id":12459749,"avatar_url":"https://avatars.githubusercontent.com/u/12459749?v=3","gravatar_id":"","url":"https://api.github.com/users/trunk-studio","html_url":"https://github.com/trunk-studio","followers_url":"https://api.github.com/users/trunk-studio/followers","following_url":"https://api.github.com/users/trunk-studio/following{/other_user}","gists_url":"https://api.github.com/users/trunk-studio/gists{/gist_id}","starred_url":"https://api.github.com/users/trunk-studio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trunk-studio/subscriptions","organizations_url":"https://api.github.com/users/trunk-studio/orgs","repos_url":"https://api.github.com/users/trunk-studio/repos","events_url":"https://api.github.com/users/trunk-studio/events{/privacy}","received_events_url":"https://api.github.com/users/trunk-studio/received_events","type":"Organization","site_admin":false},"repo":{"id":53910410,"name":"trademuch-native","full_name":"trunk-studio/trademuch-native","owner":{"login":"trunk-studio","id":12459749,"avatar_url":"https://avatars.githubusercontent.com/u/12459749?v=3","gravatar_id":"","url":"https://api.github.com/users/trunk-studio","html_url":"https://github.com/trunk-studio","followers_url":"https://api.github.com/users/trunk-studio/followers","following_url":"https://api.github.com/users/trunk-studio/following{/other_user}","gists_url":"https://api.github.com/users/trunk-studio/gists{/gist_id}","starred_url":"https://api.github.com/users/trunk-studio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trunk-studio/subscriptions","organizations_url":"https://api.github.com/users/trunk-studio/orgs","repos_url":"https://api.github.com/users/trunk-studio/repos","events_url":"https://api.github.com/users/trunk-studio/events{/privacy}","received_events_url":"https://api.github.com/users/trunk-studio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/trunk-studio/trademuch-native","description":"React Native","fork":false,"url":"https://api.github.com/repos/trunk-studio/trademuch-native","forks_url":"https://api.github.com/repos/trunk-studio/trademuch-native/forks","keys_url":"https://api.github.com/repos/trunk-studio/trademuch-native/keys{/key_id}","collaborators_url":"https://api.github.com/repos/trunk-studio/trademuch-native/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/trunk-studio/trademuch-native/teams","hooks_url":"https://api.github.com/repos/trunk-studio/trademuch-native/hooks","issue_events_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/events{/number}","events_url":"https://api.github.com/repos/trunk-studio/trademuch-native/events","assignees_url":"https://api.github.com/repos/trunk-studio/trademuch-native/assignees{/user}","branches_url":"https://api.github.com/repos/trunk-studio/trademuch-native/branches{/branch}","tags_url":"https://api.github.com/repos/trunk-studio/trademuch-native/tags","blobs_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/refs{/sha}","trees_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/trees{/sha}","statuses_url":"https://api.github.com/repos/trunk-studio/trademuch-native/statuses/{sha}","languages_url":"https://api.github.com/repos/trunk-studio/trademuch-native/languages","stargazers_url":"https://api.github.com/repos/trunk-studio/trademuch-native/stargazers","contributors_url":"https://api.github.com/repos/trunk-studio/trademuch-native/contributors","subscribers_url":"https://api.github.com/repos/trunk-studio/trademuch-native/subscribers","subscription_url":"https://api.github.com/repos/trunk-studio/trademuch-native/subscription","commits_url":"https://api.github.com/repos/trunk-studio/trademuch-native/commits{/sha}","git_commits_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/commits{/sha}","comments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/comments{/number}","issue_comment_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/comments{/number}","contents_url":"https://api.github.com/repos/trunk-studio/trademuch-native/contents/{+path}","compare_url":"https://api.github.com/repos/trunk-studio/trademuch-native/compare/{base}...{head}","merges_url":"https://api.github.com/repos/trunk-studio/trademuch-native/merges","archive_url":"https://api.github.com/repos/trunk-studio/trademuch-native/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/trunk-studio/trademuch-native/downloads","issues_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues{/number}","pulls_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls{/number}","milestones_url":"https://api.github.com/repos/trunk-studio/trademuch-native/milestones{/number}","notifications_url":"https://api.github.com/repos/trunk-studio/trademuch-native/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/trunk-studio/trademuch-native/labels{/name}","releases_url":"https://api.github.com/repos/trunk-studio/trademuch-native/releases{/id}","deployments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/deployments","created_at":"2016-03-15T03:08:18Z","updated_at":"2016-03-15T04:59:31Z","pushed_at":"2016-04-25T02:46:20Z","git_url":"git://github.com/trunk-studio/trademuch-native.git","ssh_url":"git@github.com:trunk-studio/trademuch-native.git","clone_url":"https://github.com/trunk-studio/trademuch-native.git","svn_url":"https://github.com/trunk-studio/trademuch-native","homepage":null,"size":41237,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":23,"forks":4,"open_issues":23,"watchers":0,"default_branch":"master"}},"base":{"label":"trunk-studio:develop","ref":"develop","sha":"ba57cc656a09ddbf30dc8d8e39b227dfbb3f3543","user":{"login":"trunk-studio","id":12459749,"avatar_url":"https://avatars.githubusercontent.com/u/12459749?v=3","gravatar_id":"","url":"https://api.github.com/users/trunk-studio","html_url":"https://github.com/trunk-studio","followers_url":"https://api.github.com/users/trunk-studio/followers","following_url":"https://api.github.com/users/trunk-studio/following{/other_user}","gists_url":"https://api.github.com/users/trunk-studio/gists{/gist_id}","starred_url":"https://api.github.com/users/trunk-studio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trunk-studio/subscriptions","organizations_url":"https://api.github.com/users/trunk-studio/orgs","repos_url":"https://api.github.com/users/trunk-studio/repos","events_url":"https://api.github.com/users/trunk-studio/events{/privacy}","received_events_url":"https://api.github.com/users/trunk-studio/received_events","type":"Organization","site_admin":false},"repo":{"id":53910410,"name":"trademuch-native","full_name":"trunk-studio/trademuch-native","owner":{"login":"trunk-studio","id":12459749,"avatar_url":"https://avatars.githubusercontent.com/u/12459749?v=3","gravatar_id":"","url":"https://api.github.com/users/trunk-studio","html_url":"https://github.com/trunk-studio","followers_url":"https://api.github.com/users/trunk-studio/followers","following_url":"https://api.github.com/users/trunk-studio/following{/other_user}","gists_url":"https://api.github.com/users/trunk-studio/gists{/gist_id}","starred_url":"https://api.github.com/users/trunk-studio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trunk-studio/subscriptions","organizations_url":"https://api.github.com/users/trunk-studio/orgs","repos_url":"https://api.github.com/users/trunk-studio/repos","events_url":"https://api.github.com/users/trunk-studio/events{/privacy}","received_events_url":"https://api.github.com/users/trunk-studio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/trunk-studio/trademuch-native","description":"React Native","fork":false,"url":"https://api.github.com/repos/trunk-studio/trademuch-native","forks_url":"https://api.github.com/repos/trunk-studio/trademuch-native/forks","keys_url":"https://api.github.com/repos/trunk-studio/trademuch-native/keys{/key_id}","collaborators_url":"https://api.github.com/repos/trunk-studio/trademuch-native/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/trunk-studio/trademuch-native/teams","hooks_url":"https://api.github.com/repos/trunk-studio/trademuch-native/hooks","issue_events_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/events{/number}","events_url":"https://api.github.com/repos/trunk-studio/trademuch-native/events","assignees_url":"https://api.github.com/repos/trunk-studio/trademuch-native/assignees{/user}","branches_url":"https://api.github.com/repos/trunk-studio/trademuch-native/branches{/branch}","tags_url":"https://api.github.com/repos/trunk-studio/trademuch-native/tags","blobs_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/refs{/sha}","trees_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/trees{/sha}","statuses_url":"https://api.github.com/repos/trunk-studio/trademuch-native/statuses/{sha}","languages_url":"https://api.github.com/repos/trunk-studio/trademuch-native/languages","stargazers_url":"https://api.github.com/repos/trunk-studio/trademuch-native/stargazers","contributors_url":"https://api.github.com/repos/trunk-studio/trademuch-native/contributors","subscribers_url":"https://api.github.com/repos/trunk-studio/trademuch-native/subscribers","subscription_url":"https://api.github.com/repos/trunk-studio/trademuch-native/subscription","commits_url":"https://api.github.com/repos/trunk-studio/trademuch-native/commits{/sha}","git_commits_url":"https://api.github.com/repos/trunk-studio/trademuch-native/git/commits{/sha}","comments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/comments{/number}","issue_comment_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/comments{/number}","contents_url":"https://api.github.com/repos/trunk-studio/trademuch-native/contents/{+path}","compare_url":"https://api.github.com/repos/trunk-studio/trademuch-native/compare/{base}...{head}","merges_url":"https://api.github.com/repos/trunk-studio/trademuch-native/merges","archive_url":"https://api.github.com/repos/trunk-studio/trademuch-native/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/trunk-studio/trademuch-native/downloads","issues_url":"https://api.github.com/repos/trunk-studio/trademuch-native/issues{/number}","pulls_url":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls{/number}","milestones_url":"https://api.github.com/repos/trunk-studio/trademuch-native/milestones{/number}","notifications_url":"https://api.github.com/repos/trunk-studio/trademuch-native/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/trunk-studio/trademuch-native/labels{/name}","releases_url":"https://api.github.com/repos/trunk-studio/trademuch-native/releases{/id}","deployments_url":"https://api.github.com/repos/trunk-studio/trademuch-native/deployments","created_at":"2016-03-15T03:08:18Z","updated_at":"2016-03-15T04:59:31Z","pushed_at":"2016-04-25T02:46:20Z","git_url":"git://github.com/trunk-studio/trademuch-native.git","ssh_url":"git@github.com:trunk-studio/trademuch-native.git","clone_url":"https://github.com/trunk-studio/trademuch-native.git","svn_url":"https://github.com/trunk-studio/trademuch-native","homepage":null,"size":41237,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":23,"forks":4,"open_issues":23,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214"},"html":{"href":"https://github.com/trunk-studio/trademuch-native/pull/214"},"issue":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/214"},"comments":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/issues/214/comments"},"review_comments":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214/comments"},"review_comment":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/pulls/214/commits"},"statuses":{"href":"https://api.github.com/repos/trunk-studio/trademuch-native/statuses/c14317bbaa439c3f4374fb3af7f895cd62ef857e"}}}}