diff --git a/.env.example b/.env.example index e869ae8..aa808a3 100644 --- a/.env.example +++ b/.env.example @@ -22,6 +22,4 @@ SFTP_HOST=host.com SFTP_DESTINATION_PATH_ROOT="/absolute/path/to/destination/root/folder" SFTP_BASE_URL=https://base-url.com -PAYLOAD_PUBLIC_FRONTEND_BASE_URL=https://domain.com - -RATING_LIMIT_SKIP_TOKEN=ratelimitskiptoken5e6ea45ef4e66eaa151612bdcb599df \ No newline at end of file +PAYLOAD_PUBLIC_FRONTEND_BASE_URL=https://domain.com \ No newline at end of file diff --git a/src/payload.config.ts b/src/payload.config.ts index 2b2a664..67a9b3f 100644 --- a/src/payload.config.ts +++ b/src/payload.config.ts @@ -88,9 +88,7 @@ export default buildConfig({ disable: true, }, rateLimit: { - window: 900_000, // 15 minutes - max: 500, - skip: (request) => request.headers["x-rate-limit-skip"] === process.env.RATING_LIMIT_SKIP_TOKEN, + skip: () => true, }, plugins: [ cloudStorage({ diff --git a/src/sdk.ts b/src/sdk.ts index c73b026..b506b41 100644 --- a/src/sdk.ts +++ b/src/sdk.ts @@ -77,7 +77,6 @@ const injectAuth = async (init?: RequestInit): Promise => ({ headers: { ...init?.headers, Authorization: `JWT ${await getToken()}`, - "x-rate-limit-skip": process.env.PAYLOAD_RATING_LIMIT_SKIP_TOKEN ?? "", }, });