Ensure the add new feedly feed completion handler is called when a feed is not found. Fixes #2470

This commit is contained in:
Kiel Gillard 🤪 2020-10-01 14:09:41 +10:00
parent 6bdd9ad0d6
commit 4787931c64

View File

@ -68,6 +68,13 @@ class FeedlyAddNewFeedOperation: FeedlyOperation, FeedlyOperationDelegate, Feedl
super.didCancel()
}
override func didFinish(with error: Error) {
assert(Thread.isMainThread)
addCompletionHandler?(.failure(error))
addCompletionHandler = nil
super.didFinish(with: error)
}
func feedlySearchOperation(_ operation: FeedlySearchOperation, didGet response: FeedlyFeedsSearchResponse) {
guard !isCanceled else {
return