diff --git a/BinaryObjectScanner/Data/StaticChecks.cs b/BinaryObjectScanner/Data/StaticChecks.cs index 8adbb155..4f0330c4 100644 --- a/BinaryObjectScanner/Data/StaticChecks.cs +++ b/BinaryObjectScanner/Data/StaticChecks.cs @@ -131,6 +131,11 @@ namespace BinaryObjectScanner.Data /// private static List InitCheckClasses(Assembly assembly) { + // Get information from the type param + string? interfaceName = typeof(T).FullName; + if (interfaceName == null) + return []; + // If not all types can be loaded, use the ones that could be Type?[] assemblyTypes; try @@ -142,11 +147,6 @@ namespace BinaryObjectScanner.Data assemblyTypes = rtle.Types ?? []; } - // Get information from the type param - string? interfaceName = typeof(T).FullName; - if (interfaceName == null) - return []; - // Loop through all types List classTypes = []; foreach (Type? type in assemblyTypes)