mirror of
https://github.com/supabase/supabase.git
synced 2026-10-10 20:05:06 +03:00
### What is the current behavior? Fixes FE-4056. In the Storage Explorer, if you edit a bucket's access level (public/private) via "Edit bucket", the "Get URL" action keeps generating the old signed/public URL type. Clicking the in-explorer refresh button doesn't fix it either, since it only re-lists objects and never refetches bucket metadata. Only a full browser reload resolves it. ### What is the new behavior? selectedBucket in the Storage Explorer's Valtio store is now kept in sync with the bucket query on every change, not just on project switch. "Get URL" now always reads the current public/private state, so it correctly returns a public URL or a signed URL immediately after the bucket's access level is changed - no reload required. ### Additional context Added a second effect to sync selectedBucket whenever the bucket query value changes. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Updated bucket selection state when bucket settings change, preventing stale bucket information in actions such as “Get URL.” <!-- end of auto-generated comment: release notes by coderabbit.ai -->