changing to use Type argument instead of object

integration
SignpostMarv 2012-08-31 12:57:51 +01:00 committed by Melanie
parent dff746df7b
commit 05648c2c4a
1 changed files with 3 additions and 3 deletions

View File

@ -130,9 +130,9 @@ namespace OpenSim.Region.OptionalModules.Scripting.ScriptModuleComms
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);
return mi;
@ -140,7 +140,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.ScriptModuleComms
public void RegisterScriptInvocation(object target, string meth)
{
MethodInfo mi = GetMethodInfoFromType(target, meth);
MethodInfo mi = GetMethodInfoFromType(target.GetType(), meth);
if (mi == null)
{
m_log.WarnFormat("[MODULE COMMANDS] Failed to register method {0}",meth);