Consistent handling of null array for arguments

Issue: SPR-16075

(cherry picked from commit c29b6f5)
This commit is contained in:
Juergen Hoeller
2017-10-16 15:34:18 +02:00
parent 4daf685eee
commit 03be8095ca
3 changed files with 40 additions and 30 deletions

View File

@@ -44,7 +44,7 @@ public class MethodInvoker {
private String staticMethod;
private Object[] arguments = new Object[0];
private Object[] arguments;
/** The method we will call */
private Method methodObject;
@@ -130,7 +130,7 @@ public class MethodInvoker {
* Return the arguments for the method invocation.
*/
public Object[] getArguments() {
return this.arguments;
return (this.arguments != null ? this.arguments : new Object[0]);
}