{"action":"closed","number":479,"pull_request":{"url":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479","id":229562467,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI5NTYyNDY3","html_url":"https://github.com/kickstarter/ios-oss/pull/479","diff_url":"https://github.com/kickstarter/ios-oss/pull/479.diff","patch_url":"https://github.com/kickstarter/ios-oss/pull/479.patch","issue_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/479","number":479,"state":"closed","locked":false,"title":"Delete payment methods","user":{"login":"justinswart","id":3735375,"node_id":"MDQ6VXNlcjM3MzUzNzU=","avatar_url":"https://avatars3.githubusercontent.com/u/3735375?v=4","gravatar_id":"","url":"https://api.github.com/users/justinswart","html_url":"https://github.com/justinswart","followers_url":"https://api.github.com/users/justinswart/followers","following_url":"https://api.github.com/users/justinswart/following{/other_user}","gists_url":"https://api.github.com/users/justinswart/gists{/gist_id}","starred_url":"https://api.github.com/users/justinswart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinswart/subscriptions","organizations_url":"https://api.github.com/users/justinswart/orgs","repos_url":"https://api.github.com/users/justinswart/repos","events_url":"https://api.github.com/users/justinswart/events{/privacy}","received_events_url":"https://api.github.com/users/justinswart/received_events","type":"User","site_admin":false},"body":"# What\r\n\r\nAdds the ability to delete payment methods using standard iOS deletion gestures.\r\n\r\n# Why\r\n\r\nThis is a continuation of the work done in #457 to allow users to delete payment methods. This branch is also based off the `feature-payment-methods` branch.\r\n\r\n# How\r\n\r\n`UITableView` gives us most of this functionality for free so this was fairly straightforward to implement. I've also taken an optimistic UI approach here so the credit card will be removed immediately upon deletion and we will only show it again if an error occurs.\r\n\r\nSome ways that we may want to iterate on this:\r\n\r\n-  I think we might want to confirm deletion in some way, either through an alert _after_ swiping, but _before_ performing the deletion, or potentially displaying an undo button after animating it away but not committing the deletion.\r\n- I've come up with some copy for an error alert (see below) which refers to the thing that failed to be removed as a _credit card_, do we want to stick to _payment method_ here?\r\n\r\ncc @nnekab @dannyalright for the above.\r\n\r\n# See 👀\r\n\r\n| Tap to delete | Swipe to delete | Error case |\r\n| ------------- | ------------- | ------------- |\r\n| ![2018-11-08 16 41 31](https://user-images.githubusercontent.com/3735375/48237383-3be2c500-e37b-11e8-8e3f-334635eae45f.gif) | ![2018-11-08 16 42 37](https://user-images.githubusercontent.com/3735375/48237400-4604c380-e37b-11e8-9f1c-277c61826d3e.gif) | ![2018-11-08 17 31 38](https://user-images.githubusercontent.com/3735375/48237607-405bad80-e37c-11e8-9539-d82fc191a44b.gif) |","created_at":"2018-11-09T01:33:27Z","updated_at":"2018-11-15T18:09:35Z","closed_at":"2018-11-15T18:09:35Z","merged_at":"2018-11-15T18:09:35Z","merge_commit_sha":"20c5d508787e25fe0229e12b0ea6970e49dd38c7","assignee":{"login":"Scollaco","id":3709676,"node_id":"MDQ6VXNlcjM3MDk2NzY=","avatar_url":"https://avatars2.githubusercontent.com/u/3709676?v=4","gravatar_id":"","url":"https://api.github.com/users/Scollaco","html_url":"https://github.com/Scollaco","followers_url":"https://api.github.com/users/Scollaco/followers","following_url":"https://api.github.com/users/Scollaco/following{/other_user}","gists_url":"https://api.github.com/users/Scollaco/gists{/gist_id}","starred_url":"https://api.github.com/users/Scollaco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Scollaco/subscriptions","organizations_url":"https://api.github.com/users/Scollaco/orgs","repos_url":"https://api.github.com/users/Scollaco/repos","events_url":"https://api.github.com/users/Scollaco/events{/privacy}","received_events_url":"https://api.github.com/users/Scollaco/received_events","type":"User","site_admin":false},"assignees":[{"login":"Scollaco","id":3709676,"node_id":"MDQ6VXNlcjM3MDk2NzY=","avatar_url":"https://avatars2.githubusercontent.com/u/3709676?v=4","gravatar_id":"","url":"https://api.github.com/users/Scollaco","html_url":"https://github.com/Scollaco","followers_url":"https://api.github.com/users/Scollaco/followers","following_url":"https://api.github.com/users/Scollaco/following{/other_user}","gists_url":"https://api.github.com/users/Scollaco/gists{/gist_id}","starred_url":"https://api.github.com/users/Scollaco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Scollaco/subscriptions","organizations_url":"https://api.github.com/users/Scollaco/orgs","repos_url":"https://api.github.com/users/Scollaco/repos","events_url":"https://api.github.com/users/Scollaco/events{/privacy}","received_events_url":"https://api.github.com/users/Scollaco/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":925804105,"node_id":"MDU6TGFiZWw5MjU4MDQxMDU=","url":"https://api.github.com/repos/kickstarter/ios-oss/labels/needs%20review","name":"needs review","color":"fcd753","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479/commits","review_comments_url":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479/comments","review_comment_url":"https://api.github.com/repos/kickstarter/ios-oss/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/479/comments","statuses_url":"https://api.github.com/repos/kickstarter/ios-oss/statuses/4fcad70cf83e14d7bec0b04f49214701df484505","head":{"label":"kickstarter:delete-payment-methods","ref":"delete-payment-methods","sha":"4fcad70cf83e14d7bec0b04f49214701df484505","user":{"login":"kickstarter","id":120676,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyMDY3Ng==","avatar_url":"https://avatars1.githubusercontent.com/u/120676?v=4","gravatar_id":"","url":"https://api.github.com/users/kickstarter","html_url":"https://github.com/kickstarter","followers_url":"https://api.github.com/users/kickstarter/followers","following_url":"https://api.github.com/users/kickstarter/following{/other_user}","gists_url":"https://api.github.com/users/kickstarter/gists{/gist_id}","starred_url":"https://api.github.com/users/kickstarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kickstarter/subscriptions","organizations_url":"https://api.github.com/users/kickstarter/orgs","repos_url":"https://api.github.com/users/kickstarter/repos","events_url":"https://api.github.com/users/kickstarter/events{/privacy}","received_events_url":"https://api.github.com/users/kickstarter/received_events","type":"Organization","site_admin":false},"repo":{"id":75432091,"node_id":"MDEwOlJlcG9zaXRvcnk3NTQzMjA5MQ==","name":"ios-oss","full_name":"kickstarter/ios-oss","private":false,"owner":{"login":"kickstarter","id":120676,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyMDY3Ng==","avatar_url":"https://avatars1.githubusercontent.com/u/120676?v=4","gravatar_id":"","url":"https://api.github.com/users/kickstarter","html_url":"https://github.com/kickstarter","followers_url":"https://api.github.com/users/kickstarter/followers","following_url":"https://api.github.com/users/kickstarter/following{/other_user}","gists_url":"https://api.github.com/users/kickstarter/gists{/gist_id}","starred_url":"https://api.github.com/users/kickstarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kickstarter/subscriptions","organizations_url":"https://api.github.com/users/kickstarter/orgs","repos_url":"https://api.github.com/users/kickstarter/repos","events_url":"https://api.github.com/users/kickstarter/events{/privacy}","received_events_url":"https://api.github.com/users/kickstarter/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/kickstarter/ios-oss","description":"Kickstarter for iOS. Bring new ideas to life, anywhere.","fork":false,"url":"https://api.github.com/repos/kickstarter/ios-oss","forks_url":"https://api.github.com/repos/kickstarter/ios-oss/forks","keys_url":"https://api.github.com/repos/kickstarter/ios-oss/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kickstarter/ios-oss/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kickstarter/ios-oss/teams","hooks_url":"https://api.github.com/repos/kickstarter/ios-oss/hooks","issue_events_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/events{/number}","events_url":"https://api.github.com/repos/kickstarter/ios-oss/events","assignees_url":"https://api.github.com/repos/kickstarter/ios-oss/assignees{/user}","branches_url":"https://api.github.com/repos/kickstarter/ios-oss/branches{/branch}","tags_url":"https://api.github.com/repos/kickstarter/ios-oss/tags","blobs_url":"https://api.github.com/repos/kickstarter/ios-oss/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kickstarter/ios-oss/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kickstarter/ios-oss/git/refs{/sha}","trees_url":"https://api.github.com/repos/kickstarter/ios-oss/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kickstarter/ios-oss/statuses/{sha}","languages_url":"https://api.github.com/repos/kickstarter/ios-oss/languages","stargazers_url":"https://api.github.com/repos/kickstarter/ios-oss/stargazers","contributors_url":"https://api.github.com/repos/kickstarter/ios-oss/contributors","subscribers_url":"https://api.github.com/repos/kickstarter/ios-oss/subscribers","subscription_url":"https://api.github.com/repos/kickstarter/ios-oss/subscription","commits_url":"https://api.github.com/repos/kickstarter/ios-oss/commits{/sha}","git_commits_url":"https://api.github.com/repos/kickstarter/ios-oss/git/commits{/sha}","comments_url":"https://api.github.com/repos/kickstarter/ios-oss/comments{/number}","issue_comment_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/comments{/number}","contents_url":"https://api.github.com/repos/kickstarter/ios-oss/contents/{+path}","compare_url":"https://api.github.com/repos/kickstarter/ios-oss/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kickstarter/ios-oss/merges","archive_url":"https://api.github.com/repos/kickstarter/ios-oss/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kickstarter/ios-oss/downloads","issues_url":"https://api.github.com/repos/kickstarter/ios-oss/issues{/number}","pulls_url":"https://api.github.com/repos/kickstarter/ios-oss/pulls{/number}","milestones_url":"https://api.github.com/repos/kickstarter/ios-oss/milestones{/number}","notifications_url":"https://api.github.com/repos/kickstarter/ios-oss/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kickstarter/ios-oss/labels{/name}","releases_url":"https://api.github.com/repos/kickstarter/ios-oss/releases{/id}","deployments_url":"https://api.github.com/repos/kickstarter/ios-oss/deployments","created_at":"2016-12-02T21:24:40Z","updated_at":"2018-11-15T15:10:10Z","pushed_at":"2018-11-15T18:09:35Z","git_url":"git://github.com/kickstarter/ios-oss.git","ssh_url":"git@github.com:kickstarter/ios-oss.git","clone_url":"https://github.com/kickstarter/ios-oss.git","svn_url":"https://github.com/kickstarter/ios-oss","homepage":"https://www.kickstarter.com/mobile","size":1347606,"stargazers_count":6363,"watchers_count":6363,"language":"Swift","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":923,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":923,"open_issues":2,"watchers":6363,"default_branch":"master"}},"base":{"label":"kickstarter:feature-payment-methods","ref":"feature-payment-methods","sha":"6f90116d4116c2ed16d95a1d844473fa22c56429","user":{"login":"kickstarter","id":120676,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyMDY3Ng==","avatar_url":"https://avatars1.githubusercontent.com/u/120676?v=4","gravatar_id":"","url":"https://api.github.com/users/kickstarter","html_url":"https://github.com/kickstarter","followers_url":"https://api.github.com/users/kickstarter/followers","following_url":"https://api.github.com/users/kickstarter/following{/other_user}","gists_url":"https://api.github.com/users/kickstarter/gists{/gist_id}","starred_url":"https://api.github.com/users/kickstarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kickstarter/subscriptions","organizations_url":"https://api.github.com/users/kickstarter/orgs","repos_url":"https://api.github.com/users/kickstarter/repos","events_url":"https://api.github.com/users/kickstarter/events{/privacy}","received_events_url":"https://api.github.com/users/kickstarter/received_events","type":"Organization","site_admin":false},"repo":{"id":75432091,"node_id":"MDEwOlJlcG9zaXRvcnk3NTQzMjA5MQ==","name":"ios-oss","full_name":"kickstarter/ios-oss","private":false,"owner":{"login":"kickstarter","id":120676,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEyMDY3Ng==","avatar_url":"https://avatars1.githubusercontent.com/u/120676?v=4","gravatar_id":"","url":"https://api.github.com/users/kickstarter","html_url":"https://github.com/kickstarter","followers_url":"https://api.github.com/users/kickstarter/followers","following_url":"https://api.github.com/users/kickstarter/following{/other_user}","gists_url":"https://api.github.com/users/kickstarter/gists{/gist_id}","starred_url":"https://api.github.com/users/kickstarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kickstarter/subscriptions","organizations_url":"https://api.github.com/users/kickstarter/orgs","repos_url":"https://api.github.com/users/kickstarter/repos","events_url":"https://api.github.com/users/kickstarter/events{/privacy}","received_events_url":"https://api.github.com/users/kickstarter/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/kickstarter/ios-oss","description":"Kickstarter for iOS. Bring new ideas to life, anywhere.","fork":false,"url":"https://api.github.com/repos/kickstarter/ios-oss","forks_url":"https://api.github.com/repos/kickstarter/ios-oss/forks","keys_url":"https://api.github.com/repos/kickstarter/ios-oss/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kickstarter/ios-oss/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kickstarter/ios-oss/teams","hooks_url":"https://api.github.com/repos/kickstarter/ios-oss/hooks","issue_events_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/events{/number}","events_url":"https://api.github.com/repos/kickstarter/ios-oss/events","assignees_url":"https://api.github.com/repos/kickstarter/ios-oss/assignees{/user}","branches_url":"https://api.github.com/repos/kickstarter/ios-oss/branches{/branch}","tags_url":"https://api.github.com/repos/kickstarter/ios-oss/tags","blobs_url":"https://api.github.com/repos/kickstarter/ios-oss/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kickstarter/ios-oss/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kickstarter/ios-oss/git/refs{/sha}","trees_url":"https://api.github.com/repos/kickstarter/ios-oss/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kickstarter/ios-oss/statuses/{sha}","languages_url":"https://api.github.com/repos/kickstarter/ios-oss/languages","stargazers_url":"https://api.github.com/repos/kickstarter/ios-oss/stargazers","contributors_url":"https://api.github.com/repos/kickstarter/ios-oss/contributors","subscribers_url":"https://api.github.com/repos/kickstarter/ios-oss/subscribers","subscription_url":"https://api.github.com/repos/kickstarter/ios-oss/subscription","commits_url":"https://api.github.com/repos/kickstarter/ios-oss/commits{/sha}","git_commits_url":"https://api.github.com/repos/kickstarter/ios-oss/git/commits{/sha}","comments_url":"https://api.github.com/repos/kickstarter/ios-oss/comments{/number}","issue_comment_url":"https://api.github.com/repos/kickstarter/ios-oss/issues/comments{/number}","contents_url":"https://api.github.com/repos/kickstarter/ios-oss/contents/{+path}","compare_url":"https://api.github.com/repos/kickstarter/ios-oss/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kickstarter/ios-oss/merges","archive_url":"https://api.github.com/repos/kickstarter/ios-oss/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kickstarter/ios-oss/downloads","issues_url":"https://api.github.com/repos/kickstarter/ios-oss/issues{/number}","pulls_url":"https://api.github.com/repos/kickstarter/ios-oss/pulls{/number}","milestones_url":"https://api.github.com/repos/kickstarter/ios-oss/milestones{/number}","notifications_url":"https://api.github.com/repos/kickstarter/ios-oss/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kickstarter/ios-oss/labels{/name}","releases_url":"https://api.github.com/repos/kickstarter/ios-oss/releases{/id}","deployments_url":"https://api.github.com/repos/kickstarter/ios-oss/deployments","created_at":"2016-12-02T21:24:40Z","updated_at":"2018-11-15T15:10:10Z","pushed_at":"2018-11-15T18:09:35Z","git_url":"git://github.com/kickstarter/ios-oss.git","ssh_url":"git@github.com:kickstarter/ios-oss.git","clone_url":"https://github.com/kickstarter/ios-oss.git","svn_url":"https://github.com/kickstarter/ios-oss","homepage":"https://www.kickstarter.com/mobile","size":1347606,"stargazers_count":6363,"watchers_count":6363,"language":"Swift","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":923,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":923,"open_issues":2,"watchers":6363,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479"},"html":{"href":"https://github.com/kickstarter/ios-oss/pull/479"},"issue":{"href":"https://api.github.com/repos/kickstarter/ios-oss/issues/479"},"comments":{"href":"https://api.github.com/repos/kickstarter/ios-oss/issues/479/comments"},"review_comments":{"href":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479/comments"},"review_comment":{"href":"https://api.github.com/repos/kickstarter/ios-oss/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kickstarter/ios-oss/pulls/479/commits"},"statuses":{"href":"https://api.github.com/repos/kickstarter/ios-oss/statuses/4fcad70cf83e14d7bec0b04f49214701df484505"}},"author_association":"CONTRIBUTOR","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"justinswart","id":3735375,"node_id":"MDQ6VXNlcjM3MzUzNzU=","avatar_url":"https://avatars3.githubusercontent.com/u/3735375?v=4","gravatar_id":"","url":"https://api.github.com/users/justinswart","html_url":"https://github.com/justinswart","followers_url":"https://api.github.com/users/justinswart/followers","following_url":"https://api.github.com/users/justinswart/following{/other_user}","gists_url":"https://api.github.com/users/justinswart/gists{/gist_id}","starred_url":"https://api.github.com/users/justinswart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinswart/subscriptions","organizations_url":"https://api.github.com/users/justinswart/orgs","repos_url":"https://api.github.com/users/justinswart/repos","events_url":"https://api.github.com/users/justinswart/events{/privacy}","received_events_url":"https://api.github.com/users/justinswart/received_events","type":"User","site_admin":false},"comments":4,"review_comments":19,"maintainer_can_modify":false,"commits":6,"additions":243,"deletions":40,"changed_files":11}}
{"actor":{"display_login":"justinswart"}}