Bypass init and proxy

pull/102/head
FongMi 3 years ago
parent cfd99cec5b
commit 8559591e5d
  1. 11
      app/src/main/java/com/fongmi/android/tv/api/JarLoader.java

@ -28,18 +28,17 @@ public class JarLoader {
this.spiders = new ConcurrentHashMap<>();
}
public void load(File file) throws Exception {
public void load(File file) {
spiders.clear();
proxyFun = null;
classLoader = new DexClassLoader(file.getAbsolutePath(), FileUtil.getCachePath(), null, App.get().getClassLoader());
Class<?> classInit = classLoader.loadClass("com.github.catvod.spider.Init");
Class<?> classProxy = classLoader.loadClass("com.github.catvod.spider.Proxy");
if (classInit != null) {
try {
Class<?> classInit = classLoader.loadClass("com.github.catvod.spider.Init");
Method method = classInit.getMethod("init", Context.class);
method.invoke(classInit, App.get());
}
if (classProxy != null) {
Class<?> classProxy = classLoader.loadClass("com.github.catvod.spider.Proxy");
proxyFun = classProxy.getMethod("proxy", Map.class);
} catch (Exception ignored) {
}
}

Loading…
Cancel
Save