diff --git a/Sparkle/SUAutomaticUpdateDriver.m b/Sparkle/SUAutomaticUpdateDriver.m index 20a0a065..8da35671 100644 --- a/Sparkle/SUAutomaticUpdateDriver.m +++ b/Sparkle/SUAutomaticUpdateDriver.m @@ -180,10 +180,18 @@ static const NSTimeInterval SUAutomaticUpdatePromptImpatienceTimer = 60 * 60 * 2 - (void)abortUpdateWithError:(NSError *)error { - if (self.showErrors) + if (self.showErrors) { [super abortUpdateWithError:error]; - else + } else { + // Call delegate separately here because otherwise it won't know we stopped. + // Normally this gets called by the superclass + id updaterDelegate = [self.updater delegate]; + if ([updaterDelegate respondsToSelector:@selector(updater:didAbortWithError:)]) { + [updaterDelegate updater:self.updater didAbortWithError:error]; + } + [self abortUpdate]; + } } @end diff --git a/Sparkle/SUScheduledUpdateDriver.m b/Sparkle/SUScheduledUpdateDriver.m index b51fd91d..9d6bf141 100644 --- a/Sparkle/SUScheduledUpdateDriver.m +++ b/Sparkle/SUScheduledUpdateDriver.m @@ -43,10 +43,18 @@ - (void)abortUpdateWithError:(NSError *)error { - if (self.showErrors) + if (self.showErrors) { [super abortUpdateWithError:error]; - else + } else { + // Call delegate separately here because otherwise it won't know we stopped. + // Normally this gets called by the superclass + id updaterDelegate = [self.updater delegate]; + if ([updaterDelegate respondsToSelector:@selector(updater:didAbortWithError:)]) { + [updaterDelegate updater:self.updater didAbortWithError:error]; + } + [self abortUpdate]; + } } @end