Fix possible bug (#4122)

Check for outstanding tasks to execute before the task in question seems to have invalid checks.
This commit is contained in:
Arlen22 2022-03-30 14:39:21 -04:00 committed by GitHub
parent 08d9c90dc5
commit adcef4f803
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -2596,7 +2596,8 @@ $tw.boot.isStartupTaskEligible = function(taskModule) {
for(t=0; t<remaining.length; t++) {
var task = remaining[t];
if(task.before && task.before.indexOf(name) !== -1) {
if($tw.boot.doesTaskMatchPlatform(task) || (task.name && $tw.boot.disabledStartupModules.indexOf(name) !== -1)) {
//check if the other task matches the platform and is not disabled
if($tw.boot.doesTaskMatchPlatform(task) || (task.name && $tw.boot.disabledStartupModules.indexOf(task.name) === -1)) {
return false;
}
}