Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Aragas committed May 28, 2024
1 parent 974a3aa commit ea401b4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Bannerlord.ModuleManager/ModuleUtilities.cs
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,10 @@ public static IEnumerable<ModuleIssue> ValidateModuleDependencies(IReadOnlyList<
/// <returns>Any error that were detected during inspection</returns>
public static IEnumerable<ModuleIssue> ValidateLoadOrder(IReadOnlyList<ModuleInfoExtended> modules, ModuleInfoExtended targetModule)
{
// Validate common data
foreach (var issue in ValidateModuleCommonData(targetModule))
yield return issue;

var visited = new HashSet<ModuleInfoExtended>();
foreach (var issue in ValidateLoadOrder(modules, targetModule, visited))
yield return issue;
Expand All @@ -498,10 +502,6 @@ public static IEnumerable<ModuleIssue> ValidateLoadOrder(IReadOnlyList<ModuleInf
yield break;
}

// Validate common data
foreach (var issue in ValidateModuleCommonData(targetModule))
yield return issue;

// Check that all dependencies are present
foreach (var metadata in targetModule.DependenciesToLoad().DistinctBy(x => x.Id))
{
Expand Down

0 comments on commit ea401b4

Please sign in to comment.