mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
fix(studio): skip empty SQL execution when saving Data API settings (#43605)
When saving Data API settings with only max rows changes (no table/function privilege changes), updateExposedEntities sent an empty string to pg-meta/query which failed server-side validation with 'String must contain at least 1 character(s)'. Early return when there are no SQL parts to execute.
This commit is contained in:
1 parent
2d68b69c76
commit
585724daea
1 file changed
+2
@@ -41,6 +41,8 @@ export async function updateExposedEntities({
|
||||
sqlParts.push(buildFunctionPrivilegesSql(functionNamesToRemove, 'revoke'))
|
||||
}
|
||||
|
||||
if (sqlParts.length === 0) return
|
||||
|
||||
await executeSql({
|
||||
projectRef,
|
||||
connectionString,
|
||||
|
||||
Reference in new issue
Block a user