mirror of
https://github.com/qaiu/netdisk-fast-download.git
synced 2026-01-11 17:04:13 +00:00
更新代码和文档
This commit is contained in:
@@ -183,20 +183,20 @@ public class JsPlaygroundExecutor {
|
||||
// 取消超时任务
|
||||
timeoutTask.cancel(false);
|
||||
|
||||
if (error != null) {
|
||||
if (error != null) {
|
||||
if (error instanceof CancellationException) {
|
||||
String timeoutMsg = "JavaScript执行超时(超过" + EXECUTION_TIMEOUT_SECONDS + "秒),已强制中断";
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
}
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
promise.complete(result);
|
||||
}
|
||||
} else {
|
||||
promise.complete(result);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
return promise.future();
|
||||
}
|
||||
@@ -258,20 +258,20 @@ public class JsPlaygroundExecutor {
|
||||
// 取消超时任务
|
||||
timeoutTask.cancel(false);
|
||||
|
||||
if (error != null) {
|
||||
if (error != null) {
|
||||
if (error instanceof CancellationException) {
|
||||
String timeoutMsg = "JavaScript执行超时(超过" + EXECUTION_TIMEOUT_SECONDS + "秒),已强制中断";
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
}
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
promise.complete(result);
|
||||
}
|
||||
} else {
|
||||
promise.complete(result);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
return promise.future();
|
||||
}
|
||||
@@ -332,20 +332,20 @@ public class JsPlaygroundExecutor {
|
||||
// 取消超时任务
|
||||
timeoutTask.cancel(false);
|
||||
|
||||
if (error != null) {
|
||||
if (error != null) {
|
||||
if (error instanceof CancellationException) {
|
||||
String timeoutMsg = "JavaScript执行超时(超过" + EXECUTION_TIMEOUT_SECONDS + "秒),已强制中断";
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
playgroundLogger.errorJava(timeoutMsg);
|
||||
log.error(timeoutMsg);
|
||||
promise.fail(new RuntimeException(timeoutMsg));
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
}
|
||||
} else {
|
||||
Throwable cause = error.getCause();
|
||||
promise.fail(cause != null ? cause : error);
|
||||
promise.complete(result);
|
||||
}
|
||||
} else {
|
||||
promise.complete(result);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
return promise.future();
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ import java.util.regex.Pattern;
|
||||
*/
|
||||
public class LzTool extends PanBase {
|
||||
|
||||
public static final String SHARE_URL_PREFIX = "https://wwww.lanzoum.com";
|
||||
public static final String SHARE_URL_PREFIX = "https://wwwwp.lanzoup.com";
|
||||
MultiMap headers0 = HeaderUtils.parseHeaders("""
|
||||
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7
|
||||
Accept-Encoding: gzip, deflate
|
||||
|
||||
Reference in New Issue
Block a user