changing to use Type argument instead of object
parent
dff746df7b
commit
05648c2c4a
|
@ -130,9 +130,9 @@ namespace OpenSim.Region.OptionalModules.Scripting.ScriptModuleComms
|
||||||
m_scriptModule.PostScriptEvent(script, "link_message", args);
|
m_scriptModule.PostScriptEvent(script, "link_message", args);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static MethodInfo GetMethodInfoFromType(object target, string meth)
|
private static MethodInfo GetMethodInfoFromType(Type target, string meth)
|
||||||
{
|
{
|
||||||
MethodInfo mi = target.GetType().GetMethod(meth,
|
MethodInfo mi = target.GetMethod(meth,
|
||||||
BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance);
|
BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance);
|
||||||
|
|
||||||
return mi;
|
return mi;
|
||||||
|
@ -140,7 +140,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.ScriptModuleComms
|
||||||
|
|
||||||
public void RegisterScriptInvocation(object target, string meth)
|
public void RegisterScriptInvocation(object target, string meth)
|
||||||
{
|
{
|
||||||
MethodInfo mi = GetMethodInfoFromType(target, meth);
|
MethodInfo mi = GetMethodInfoFromType(target.GetType(), meth);
|
||||||
if (mi == null)
|
if (mi == null)
|
||||||
{
|
{
|
||||||
m_log.WarnFormat("[MODULE COMMANDS] Failed to register method {0}",meth);
|
m_log.WarnFormat("[MODULE COMMANDS] Failed to register method {0}",meth);
|
||||||
|
|
Loading…
Reference in New Issue