feat(storage-vercel-blob): allow fallback to disk if token not set (#10005)

Previously with `@payloadcms/plugin-storage-blob`, if token was not set,
the plugin would throw an error. This caused a less-than-ideal developer
experience.

With this change, if the `token` value is undefined:
- Local storage will be used as a fallback
- The error will no longer be thrown.
This commit is contained in:
Elliot DeNolf
2024-12-16 16:40:22 -05:00
committed by GitHub
parent f54e180370
commit fa49e04cf8
2 changed files with 11 additions and 8 deletions

View File

@@ -3,7 +3,6 @@ import type { CollectionConfig } from 'payload'
export const Media: CollectionConfig = {
slug: 'media',
upload: {
disableLocalStorage: true,
resizeOptions: {
position: 'center',
width: 200,