Simplify type check

This commit is contained in:
Paul Pacheco 2020-09-26 23:05:32 -05:00
parent 9077cc7fd7
commit 54f96309da

View File

@ -79,10 +79,10 @@ static void LoadReaders(AssemblyDefinition currentAssembly, TypeDefinition klass
if (method.Parameters.Count != 1)
continue;
if (method.Parameters[0].ParameterType.FullName != "Mirror.NetworkReader")
if (!method.Parameters[0].ParameterType.Is<NetworkReader>())
continue;
if (method.ReturnType.FullName == "System.Void")
if (method.ReturnType.Is(typeof(void)))
continue;
if (!method.HasCustomAttribute<System.Runtime.CompilerServices.ExtensionAttribute>())