Merge pull request #574 from chlupac/OqtaneIgnore

OqtaneIgnore implementation fix
This commit is contained in:
Shaun Walker
2020-06-01 14:58:04 -04:00
committed by GitHub
7 changed files with 12 additions and 14 deletions

View File

@ -80,9 +80,14 @@ namespace System.Reflection
.Where(a => Utilities.GetFullTypeName(a.GetName().Name) != "Oqtane.Client");
}
/// <summary>
/// Checks if type should be ignored by oqtane dynamic loader
/// </summary>
/// <param name="type">Checked type</param>
/// <returns></returns>
public static bool IsOqtaneIgnore(this Type type)
{
return Attribute.IsDefined(type, typeof(OqtaneIgnoreAttribute));
return Attribute.IsDefined(type, typeof(OqtaneIgnoreAttribute)) || type.IsAbstract || type.IsGenericType;
}
}
}