Skip to content

Commit 81682c8

Browse files
committed
Fix bug due to ClassNode no longer having toString
1 parent 6a6bb89 commit 81682c8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/java/club/bytecode/the/jda/JDA.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ public static byte[] dumpClassToBytes(ClassNode cn) {
259259
public static final String HACK_PREFIX = "\0JDA-hack";
260260

261261
public static File getClassFileProxy(ClassNode cn) {
262-
return new File('/' + HACK_PREFIX, cn + ".class");
262+
return new File('/' + HACK_PREFIX, cn.name + ".class");
263263
}
264264

265265
public static String extractProxyClassName(String fileName) {

src/main/java/club/bytecode/the/jda/decompilers/FernflowerDecompiler.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public String decompileClassNode(FileContainer container, final ClassNode cn) {
7676
requestedCn = container.loadClassFile(container.findClassfile(className));
7777
if (requestedCn == null) {
7878
System.err.println("Couldn't load " + externalPath);
79-
throw new IOException(container + "$" + cn + " is missing");
79+
throw new IOException(container + "$" + cn.name + " is missing");
8080
}
8181
applyFilters(requestedCn);
8282
classCache.put(className, requestedCn);

0 commit comments

Comments
 (0)