Skip to content

Commit

Permalink
Fix for the case that wrong number of args are given to constructor.
Browse files Browse the repository at this point in the history
  • Loading branch information
yokolet committed Jan 8, 2011
1 parent 1b01bfb commit ce516bd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/org/jruby/java/proxies/JavaProxy.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public Object getObject() {
// this resulted in object being null after unmarshalling...
if (object == null) {
if (javaObject == null) {
throw getRuntime().newRuntimeError("Java wrapper with no contents: " + this);
throw getRuntime().newRuntimeError("Java wrapper with no contents: " + this.getMetaClass().getName());
} else {
object = javaObject.getValue();
}
Expand Down
4 changes: 2 additions & 2 deletions src/org/jruby/javasupport/Java.java
Original file line number Diff line number Diff line change
Expand Up @@ -469,9 +469,9 @@ public static RubyModule getProxyClass(Ruby runtime, JavaClass javaClass) {
Class<?>[] interfaces = c.getInterfaces();
for (int i = interfaces.length; --i >= 0;) {
JavaClass ifc = JavaClass.get(runtime, interfaces[i]);
//if (interfaces[i] != java.util.Map.class) {
if (interfaces[i] != java.util.Map.class) {
proxyClass.includeModule(getInterfaceModule(runtime, ifc));
//}
}
}
if (Modifier.isPublic(c.getModifiers())) {
addToJavaPackageModule(proxyClass, javaClass);
Expand Down

0 comments on commit ce516bd

Please sign in to comment.