Fix not observing driver finishing notifications

This commit is contained in:
Zorg committed 2016-02-28 20:16:47 -05:00
1 parent 34ad4cfd6b
commit 7f494f13be
1 file changed
+4
+4
View File
@@ -67,6 +67,8 @@ NSString *const SUUpdaterAppcastNotificationKey = @"SUUpdaterAppCastNotification
_userUpdaterDriver = userUpdaterDriver;
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(updateDriverDidFinish:) name:SUUpdateDriverFinishedNotification object:nil];
[self startUpdateCycle];
return self;
@@ -503,6 +505,8 @@ static void SUCheckForUpdatesInBgReachabilityCheck(__weak SUUpdater *updater, SU
- (void)dealloc
{
// Remove updater did finish notification
[[NSNotificationCenter defaultCenter] removeObserver:self];
[self.userUpdaterDriver invalidateUpdateCheckTimer];
}