mirror of
https://github.com/2006-Scape/Parabot.git
synced 2026-07-03 08:39:09 +00:00
@@ -125,6 +125,14 @@ public class ClassRedirect {
|
||||
return c.getResourceAsStream(res);
|
||||
}
|
||||
|
||||
public static boolean desiredAssertionStatus(Class<?> c) {
|
||||
if (validStack()) {
|
||||
return c.desiredAssertionStatus();
|
||||
}
|
||||
|
||||
return !c.getName().contains("parabot") && c.desiredAssertionStatus();
|
||||
}
|
||||
|
||||
private static boolean validStack() {
|
||||
Exception e = new Exception();
|
||||
for (StackTraceElement elem : e.getStackTrace()) {
|
||||
|
||||
Reference in New Issue
Block a user