refactor: standardize access token variable naming across routes

This commit is contained in:
Ardeman
2025-03-12 20:46:54 +08:00
parent f423f3e1c0
commit 1ce5a2130b
22 changed files with 127 additions and 94 deletions
+2 -2
View File
@@ -10,7 +10,7 @@ import { handleCookie } from '~/libs/cookies'
import type { Route } from './+types/actions.admin.upload'
export const action = async ({ request }: Route.ActionArgs) => {
const { staffToken } = await handleCookie(request)
const { staffToken: accessToken } = await handleCookie(request)
try {
const {
@@ -29,7 +29,7 @@ export const action = async ({ request }: Route.ActionArgs) => {
const { data: uploadData } = await uploadFileRequest({
payload,
accessToken: staffToken,
accessToken,
})
return data(