refactor(api): 为API函数添加返回类型注解

- 为book_download函数添加ResponseData返回类型
- 为video_findDeduplication函数添加ResponseData返回类型
- 为video_deduplication函数添加ResponseData返回类型
- 为video_hasTorrent函数添加ResponseData返回类型
- 为torrent_deduplication函数添加ResponseData返回类型
- 为image_export函数添加ResponseData返回类型
- 为image_hasTorrent函数添加ResponseData返回类型
- 为music_rename函数添加ResponseData返回类型
- 为test函数添加ResponseData返回类型
This commit is contained in:
2026-05-08 00:18:52 +08:00
parent 72cb8c796f
commit 30c9450492
+9 -9
View File
@@ -2,25 +2,25 @@ import request from "../utils/request.ts"
type ResponseData = Promise<{ code: number, message: Array<never> }>
export function book_download() {
export function book_download():ResponseData {
return request({
url: "/book/download",
})
}
export function video_findDeduplication() {
export function video_findDeduplication():ResponseData {
return request({
url: "/video/findDeduplication",
})
}
export function video_deduplication() {
export function video_deduplication():ResponseData {
return request({
url: "/video/deduplication",
})
}
export function video_hasTorrent() {
export function video_hasTorrent():ResponseData {
return request({
url: "/video/hasTorrent",
})
@@ -32,31 +32,31 @@ export function file_rename(): ResponseData {
})
}
export function torrent_deduplication() {
export function torrent_deduplication():ResponseData {
return request({
url: "/torrent/deduplication",
})
}
export function image_export() {
export function image_export():ResponseData {
return request({
url: "/image/export",
})
}
export function image_hasTorrent() {
export function image_hasTorrent():ResponseData {
return request({
url: "/image/hasTorrent",
})
}
export function music_rename() {
export function music_rename():ResponseData {
return request({
url: "/music/rename",
})
}
export function test() {
export function test():ResponseData {
return request({
url: "/test",
})