mirror of
https://github.com/opensim/opensim.git
synced 2026-05-23 00:56:50 +08:00
changing to use Type argument instead of object
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user