Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

Fix https://sentry.io/organizations/supabase/issues/3663157841

Joshen Lim51ec11d3c843
diff --git a/studio/components/layouts/StorageLayout/StorageLayout.tsx b/studio/components/layouts/StorageLayout/StorageLayout.tsx
index 6f6c3a13491..031a5935c33 100644
--- a/studio/components/layouts/StorageLayout/StorageLayout.tsx
+++ b/studio/components/layouts/StorageLayout/StorageLayout.tsx
@@ -67,7 +67,7 @@ const StorageLayout: FC<Props> = ({ title, children }) => {
const onSelectCreateBucket = async (bucketName: string, isPublic: boolean) => {
const bucket = await createBucket(bucketName, isPublic)
- if (bucket.name) router.push(`/project/${ref}/storage/buckets/${bucket.name}`)
+ if (bucket !== undefined) router.push(`/project/${ref}/storage/buckets/${bucket.name}`)
}
const onSelectDeleteBucket = async (bucket: any) => {
diff --git a/studio/localStores/storageExplorer/StorageExplorerStore.js b/studio/localStores/storageExplorer/StorageExplorerStore.js
index 9980b30e17b..def4f9bc121 100644
--- a/studio/localStores/storageExplorer/StorageExplorerStore.js
+++ b/studio/localStores/storageExplorer/StorageExplorerStore.js
@@ -466,7 +466,8 @@ class StorageExplorerStore {
message: error.message,
category: 'error',
})
- return this.closeCreateBucketModal()
+ this.closeCreateBucketModal()
+ return undefined
}
await this.fetchBuckets()