Skip to content

Commit 3b8b444

Browse files
use return result async if needed where actual comment was 😛
1 parent dc79bed commit 3b8b444

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

Sources/Apollo/ApolloStore.swift

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,9 @@ public final class ApolloStore {
5555
self.cacheLock.withWriteLock {
5656
self.cache.clearPromise()
5757
}.andThen {
58-
guard let completion = completion else {
59-
return
60-
}
61-
callbackQueue.async {
62-
completion(.success(()))
63-
}
58+
DispatchQueue.apollo_returnResultAsyncIfNeeded(on: callbackQueue,
59+
action: completion,
60+
result: .success(()))
6461
}
6562
}
6663
}

0 commit comments

Comments
 (0)