From 3af0468062dbc0c67eb988458aa7b82d3b414595 Mon Sep 17 00:00:00 2001 From: Alessio Gravili Date: Wed, 5 Mar 2025 16:45:24 -0700 Subject: [PATCH] fix: add missing auth property to new defaults function (#11561) https://github.com/payloadcms/payload/pull/10794 added new defaults the config - however, these were only added to the deprecated `defaults` object, which caused our CI to fail. This PR adds them to the new `addDefaultsToConfig` function --- packages/payload/src/config/defaults.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/payload/src/config/defaults.ts b/packages/payload/src/config/defaults.ts index 6986168932..12761de1a1 100644 --- a/packages/payload/src/config/defaults.ts +++ b/packages/payload/src/config/defaults.ts @@ -152,5 +152,10 @@ export const addDefaultsToConfig = (config: Config): Config => { } config.upload = config.upload ?? {} + config.auth = { + jwtOrder: ['JWT', 'Bearer', 'cookie'], + ...(config.auth || {}), + } + return config }