Skip to content

Commit d8bb666

Browse files
Simone ManganelliSimone Manganelli
authored andcommitted
'Check Now' button is now still enabled even if automatically checking for updates is off (bug #200)
1 parent 1cbc626 commit d8bb666

1 file changed

Lines changed: 8 additions & 12 deletions

File tree

Plugin/SparkleManager.m

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -106,18 +106,14 @@ - (void)startAutomaticallyCheckingForUpdates {
106106
// If the key isn't set yet, default to YES, automatically check for updates.
107107
[[CTFUserDefaultsController standardUserDefaults] setBool:YES forKey:sAutomaticallyCheckForUpdates];
108108
}
109-
if ([[CTFUserDefaultsController standardUserDefaults] boolForKey:sAutomaticallyCheckForUpdates]) {
110-
static BOOL checkedForUpdate = NO;
111-
if (!checkedForUpdate) {
112-
checkedForUpdate = YES;
113-
114-
SUUpdater *updater = [self _updater];
115-
if (_canUpdate) {
116-
[updater checkForUpdatesInBackground];
117-
[updater setAutomaticallyChecksForUpdates:YES];
118-
}
119-
}
120-
}
109+
110+
SUUpdater *updater = [self _updater];
111+
if ([[CTFUserDefaultsController standardUserDefaults] boolForKey:sAutomaticallyCheckForUpdates]) {
112+
if (_canUpdate) {
113+
[updater checkForUpdatesInBackground];
114+
[updater setAutomaticallyChecksForUpdates:YES];
115+
}
116+
}
121117
}
122118

123119
- (void)checkForUpdates {

0 commit comments

Comments
 (0)