mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-05-29 09:00:18 +09:00
add todo
This commit is contained in:
parent
41779daee8
commit
6fad00f5bc
@ -63,7 +63,7 @@ export class BilibiliMusicRecognitionTool extends Tool implements RequestTool {
|
|||||||
targetSec: number,
|
targetSec: number,
|
||||||
) {
|
) {
|
||||||
// get http://10.0.1.3:32345/api/recog_music_in_bili_video?video_aid=170001&pid=1&target_sec=14
|
// get http://10.0.1.3:32345/api/recog_music_in_bili_video?video_aid=170001&pid=1&target_sec=14
|
||||||
|
// TODO open-source the forwarding server, and put the server address in an environment variable
|
||||||
const url = `http://10.0.1.3:32345/api/recog_music_in_bili_video?video_aid=${videoAid}&pid=${pid}&target_sec=${targetSec}`;
|
const url = `http://10.0.1.3:32345/api/recog_music_in_bili_video?video_aid=${videoAid}&pid=${pid}&target_sec=${targetSec}`;
|
||||||
|
|
||||||
const headers = {
|
const headers = {
|
||||||
@ -77,6 +77,7 @@ export class BilibiliMusicRecognitionTool extends Tool implements RequestTool {
|
|||||||
);
|
);
|
||||||
|
|
||||||
if (!response.ok) {
|
if (!response.ok) {
|
||||||
|
// unify all errors' type (string result or Error)
|
||||||
throw new Error(`HTTP error! status: ${response.status}`);
|
throw new Error(`HTTP error! status: ${response.status}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user