Skip to content

Commit 9b63055

Browse files
committed
Update AssemblyExtensions.cs
1 parent df01c0f commit 9b63055

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

org.mixedrealitytoolkit.core/Utilities/Extensions/AssemblyExtensions.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,15 @@ namespace MixedReality.Toolkit
1414
public static class AssemblyExtensions
1515
{
1616
/// <summary>
17-
/// Assembly.GetTypes() can throw in some cases. This extension will catch that exception and return only the types which were successfully loaded from the assembly.
17+
/// Assembly.GetTypes() can throw in some cases. This extension will catch that exception and return only the types which were successfully loaded from the assembly.
1818
/// </summary>
1919
public static IEnumerable<Type> GetLoadableTypes(this Assembly @this)
2020
{
21+
if (@this == null)
22+
{
23+
throw new ArgumentNullException(nameof(@this), "Assembly cannot be null.");
24+
}
25+
2126
try
2227
{
2328
return @this.GetTypes();

0 commit comments

Comments
 (0)