Fixes for binder not being able to get proper method

This commit is contained in:
Deukhoofd committed 2018-12-09 12:25:29 +01:00
1 parent 92586e4939
commit fb2af879c9
1 file changed
+8
@@ -74,6 +74,14 @@ namespace Upsilon.BaseTypes.UserData
continue;
}
if (!typeof(ScriptType).IsAssignableFrom(matchParameter.ParameterType) &&
argument is IUserData ud)
{
var csharpType = ud.GetCSharpType();
if (matchParameter.ParameterType.IsAssignableFrom(csharpType))
continue;
}
if (!matchParameter.ParameterType.IsAssignableFrom(argumentType))
{
validMatch = false;