{"action":"created","issue":{"url":"https://api.github.com/repos/xamarin/Essentials/issues/561","repository_url":"https://api.github.com/repos/xamarin/Essentials","labels_url":"https://api.github.com/repos/xamarin/Essentials/issues/561/labels{/name}","comments_url":"https://api.github.com/repos/xamarin/Essentials/issues/561/comments","events_url":"https://api.github.com/repos/xamarin/Essentials/issues/561/events","html_url":"https://github.com/xamarin/Essentials/issues/561","id":373909392,"node_id":"MDU6SXNzdWUzNzM5MDkzOTI=","number":561,"title":"[Secure Storage] Should not throw when removing key that doesn't exist.","user":{"login":"domagojmedo","id":12157224,"node_id":"MDQ6VXNlcjEyMTU3MjI0","avatar_url":"https://avatars0.githubusercontent.com/u/12157224?v=4","gravatar_id":"","url":"https://api.github.com/users/domagojmedo","html_url":"https://github.com/domagojmedo","followers_url":"https://api.github.com/users/domagojmedo/followers","following_url":"https://api.github.com/users/domagojmedo/following{/other_user}","gists_url":"https://api.github.com/users/domagojmedo/gists{/gist_id}","starred_url":"https://api.github.com/users/domagojmedo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/domagojmedo/subscriptions","organizations_url":"https://api.github.com/users/domagojmedo/orgs","repos_url":"https://api.github.com/users/domagojmedo/repos","events_url":"https://api.github.com/users/domagojmedo/events{/privacy}","received_events_url":"https://api.github.com/users/domagojmedo/received_events","type":"User","site_admin":false},"labels":[{"id":842976899,"node_id":"MDU6TGFiZWw4NDI5NzY4OTk=","url":"https://api.github.com/repos/xamarin/Essentials/labels/bug","name":"bug","color":"d73a4a","default":true},{"id":883953976,"node_id":"MDU6TGFiZWw4ODM5NTM5NzY=","url":"https://api.github.com/repos/xamarin/Essentials/labels/ready%20to%20implement","name":"ready to implement","color":"ea69ce","default":false},{"id":860709954,"node_id":"MDU6TGFiZWw4NjA3MDk5NTQ=","url":"https://api.github.com/repos/xamarin/Essentials/labels/up%20for%20grabs","name":"up for grabs","color":"c2e0c6","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/xamarin/Essentials/milestones/10","html_url":"https://github.com/xamarin/Essentials/milestone/10","labels_url":"https://api.github.com/repos/xamarin/Essentials/milestones/10/labels","id":3789096,"node_id":"MDk6TWlsZXN0b25lMzc4OTA5Ng==","number":10,"title":"1.0.0","description":null,"creator":{"login":"Redth","id":271950,"node_id":"MDQ6VXNlcjI3MTk1MA==","avatar_url":"https://avatars1.githubusercontent.com/u/271950?v=4","gravatar_id":"","url":"https://api.github.com/users/Redth","html_url":"https://github.com/Redth","followers_url":"https://api.github.com/users/Redth/followers","following_url":"https://api.github.com/users/Redth/following{/other_user}","gists_url":"https://api.github.com/users/Redth/gists{/gist_id}","starred_url":"https://api.github.com/users/Redth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Redth/subscriptions","organizations_url":"https://api.github.com/users/Redth/orgs","repos_url":"https://api.github.com/users/Redth/repos","events_url":"https://api.github.com/users/Redth/events{/privacy}","received_events_url":"https://api.github.com/users/Redth/received_events","type":"User","site_admin":false},"open_issues":4,"closed_issues":37,"state":"open","created_at":"2018-11-01T20:43:47Z","updated_at":"2018-11-05T23:59:21Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2018-10-25T11:52:57Z","updated_at":"2018-11-07T13:37:13Z","closed_at":"2018-11-05T22:46:42Z","author_association":"CONTRIBUTOR","body":"On SecureStorage iOS implementation\r\n\r\n    bool RemoveRecord(SecRecord record)\r\n    {\r\n            var result = SecKeyChain.Remove(record);\r\n            if (result != SecStatusCode.Success)\r\n                throw new Exception(string.Format($\"Error removing record: {result}\"));\r\n\r\n            return true;\r\n    }\r\n\r\nIt's possible to get \r\n\r\n> System.Exception: Error removing record: ItemNotFound\r\n\r\nShould that status code maybe not throw exception? We are trying to remove it and it's not there, so the end result is the same.\r\n\r\nStack trace I got\r\n\r\n\r\n> Xamarin.Essentials KeyChain.RemoveRecord (Security.SecRecord record)\r\n> Xamarin.Essentials KeyChain.SetValueForKey (System.String value, System.String key, System.String service)\r\n> Xamarin.Essentials SecureStorage.SetAsync (System.String key, System.String value, Security.SecAccessible accessible)\r\n> Xamarin.Essentials SecureStorage.PlatformSetAsync (System.String key, System.String data)\r\n> Xamarin.Essentials SecureStorage.SetAsync (System.String key, System.String value)"},"comment":{"url":"https://api.github.com/repos/xamarin/Essentials/issues/comments/436624814","html_url":"https://github.com/xamarin/Essentials/issues/561#issuecomment-436624814","issue_url":"https://api.github.com/repos/xamarin/Essentials/issues/561","id":436624814,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNjYyNDgxNA==","user":{"login":"mattleibow","id":1096616,"node_id":"MDQ6VXNlcjEwOTY2MTY=","avatar_url":"https://avatars0.githubusercontent.com/u/1096616?v=4","gravatar_id":"","url":"https://api.github.com/users/mattleibow","html_url":"https://github.com/mattleibow","followers_url":"https://api.github.com/users/mattleibow/followers","following_url":"https://api.github.com/users/mattleibow/following{/other_user}","gists_url":"https://api.github.com/users/mattleibow/gists{/gist_id}","starred_url":"https://api.github.com/users/mattleibow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattleibow/subscriptions","organizations_url":"https://api.github.com/users/mattleibow/orgs","repos_url":"https://api.github.com/users/mattleibow/repos","events_url":"https://api.github.com/users/mattleibow/events{/privacy}","received_events_url":"https://api.github.com/users/mattleibow/received_events","type":"User","site_admin":false},"created_at":"2018-11-07T13:37:13Z","updated_at":"2018-11-07T13:37:13Z","author_association":"CONTRIBUTOR","body":"It should not throw. It is using `Preferences` under the hood, which is fine for removing keys that do not exist."}}
{"actor":{"display_login":"mattleibow"}}