Implement CloudKit feed add.

This commit is contained in:
Maurice Parker
2020-03-29 03:43:20 -05:00
parent ecc20ad9e3
commit 6ce82fc28b
7 changed files with 138 additions and 44 deletions

View File

@@ -58,16 +58,12 @@ class AddFeedController: AddFeedWindowControllerDelegate {
return
}
BatchUpdate.shared.start()
account.createWebFeed(url: url.absoluteString, name: title, container: container) { result in
DispatchQueue.main.async {
self.endShowingProgress()
}
BatchUpdate.shared.end()
switch result {
case .success(let feed):
NotificationCenter.default.post(name: .UserDidAddFeed, object: self, userInfo: [UserInfoKey.webFeed: feed])