Simplify asynchronous tasks

This commit is contained in:
topjohnwu
2018-08-02 00:41:10 +08:00
parent 075737a4ec
commit 9ac71ff8af
19 changed files with 325 additions and 385 deletions
@@ -11,7 +11,7 @@ public class UpdateCheckService extends JobService {
@Override
public boolean onStartJob(JobParameters params) {
Shell.getShell();
new CheckUpdates(true).setCallBack(() -> jobFinished(params, false)).exec();
CheckUpdates.check(() -> jobFinished(params, false));
return true;
}