mirror of
https://github.com/Nezumi-2711/next-gdrive-index.git
synced 2026-09-22 13:38:38 +00:00
update: Add dynamic configuration
This commit is contained in:
@@ -4,13 +4,17 @@ import { encryptionService, gdrive } from "~/lib/utils.server";
|
||||
|
||||
import config from "config";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
type Props = {
|
||||
params: {
|
||||
params: Promise<{
|
||||
encryptedId: string;
|
||||
};
|
||||
}>;
|
||||
};
|
||||
|
||||
export async function GET(request: NextRequest, { params: { encryptedId } }: Props) {
|
||||
export async function GET(request: NextRequest, { params }: Props) {
|
||||
const { encryptedId } = await params;
|
||||
|
||||
try {
|
||||
const decryptedId = await encryptionService.decrypt(encryptedId);
|
||||
const { data } = await gdrive.files.get({
|
||||
|
||||
@@ -6,6 +6,8 @@ import { encryptionService } from "~/lib/utils.server";
|
||||
|
||||
import config from "config";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
type Props = {
|
||||
params: Promise<{
|
||||
encryptedId: string;
|
||||
|
||||
Reference in New Issue
Block a user