Skip to content

Commit

Permalink
Update MethodBaseSerializer.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
alelom authored and Fraser Greenroyd committed Dec 14, 2022
1 parent 3481ef7 commit 43ee03d
Showing 1 changed file with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,14 @@ private MethodBase GetMethod(string methodName, string typeName, List<string> pa
{
try
{
if (methodName == ".ctor")
method = type.GetConstructor(types.ToArray());
else
method = type.GetMethod(methodName, types.ToArray());
Type[] typesArray = types.ToArray();
if (typesArray != null)
{
if (methodName == ".ctor")
method = type.GetConstructor(typesArray);
else
method = type.GetMethod(methodName, typesArray);
}
}
catch { }
}
Expand Down

0 comments on commit 43ee03d

Please sign in to comment.