Skip to content

Commit 45a30cf

Browse files
committed
update exception message in GetCallingType()
1 parent 0b1c931 commit 45a30cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Utility.CommandLine.Arguments/Arguments.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ internal static Type GetCallingType(string caller)
9292

9393
if (callingMethod == default(MethodBase))
9494
{
95-
throw new InvalidOperationException("Error populating arguments; Unable to determine the containing type of Main(). Use Populate(typeof(<class containing main>))");
95+
throw new InvalidOperationException($"Unable to determine the containing type of the calling method '{caller}'. Explicitly specify the originating Type.");
9696
}
9797

9898
return callingMethod.DeclaringType;

0 commit comments

Comments
 (0)