fix page api url; fix url encode; fix memory > int32 change it to big int
This commit is contained in:
+2
-2
@@ -30,7 +30,7 @@ export default function UploadPage() {
|
||||
// 获取当前版本信息
|
||||
const fetchCurrentVersion = useCallback(async () => {
|
||||
try {
|
||||
const response = await fetch('/api/api/version')
|
||||
const response = await fetch('/api/version')
|
||||
if (response.ok) {
|
||||
const data: VersionInfo = await response.json()
|
||||
setCurrentVersion(data)
|
||||
@@ -71,7 +71,7 @@ export default function UploadPage() {
|
||||
formData.append('version', newVersion)
|
||||
|
||||
try {
|
||||
const response = await fetch('/api/upload/version', {
|
||||
const response = await fetch('/upload/version', {
|
||||
method: 'POST',
|
||||
body: formData
|
||||
})
|
||||
|
||||
@@ -46,7 +46,7 @@ async function handleVersionUpload(req: NextRequest) {
|
||||
|
||||
const protocol = req.headers.get('x-forwarded-proto') || 'http'
|
||||
const host = req.headers.get('host')
|
||||
const downloadUrl = `${protocol}://${host}/api/downloads/${storedFile.id}`
|
||||
const downloadUrl = `${protocol}://${host}/downloads/${storedFile.id}`
|
||||
|
||||
return NextResponse.json({
|
||||
version,
|
||||
|
||||
Reference in New Issue
Block a user