Skip to content

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

fix(studio): clarify default privileges toggle covers tables (#45458)

Iniane61853c59cc5
diff --git a/apps/studio/components/interfaces/ProjectCreation/SecurityOptions.tsx b/apps/studio/components/interfaces/ProjectCreation/SecurityOptions.tsx
index 20207b00b43..ebb0465d0c8 100644
--- a/apps/studio/components/interfaces/ProjectCreation/SecurityOptions.tsx
+++ b/apps/studio/components/interfaces/ProjectCreation/SecurityOptions.tsx
@@ -99,11 +99,10 @@ export const SecurityOptions = ({ form, layout = 'horizontal' }: SecurityOptions
<FormLabel
className={cn('text-sm text-foreground', !dataApi && 'text-foreground-muted')}
>
- Automatically expose new tables and functions
+ Automatically expose new tables
</FormLabel>
<FormDescription className="text-foreground-lighter">
- Grants privileges to Data API roles by default, exposing new tables and
- functions.
+ Grants privileges to Data API roles by default, exposing new tables.
<br />
<strong className="font-medium text-foreground-light">
We recommend disabling this to control access manually.
diff --git a/apps/studio/components/interfaces/Settings/API/PostgrestConfig.tsx b/apps/studio/components/interfaces/Settings/API/PostgrestConfig.tsx
index 38828405e19..c1d3fcdaf0e 100644
--- a/apps/studio/components/interfaces/Settings/API/PostgrestConfig.tsx
+++ b/apps/studio/components/interfaces/Settings/API/PostgrestConfig.tsx
@@ -393,8 +393,8 @@ export const PostgrestConfig = () => {
<FormItem>
<FormItemLayout
layout="flex-row-reverse"
- label="Automatically expose new tables and functions"
- description="Grants privileges to Data API roles by default, exposing new tables and functions. We recommend disabling this to control access manually."
+ label="Automatically expose new tables"
+ description="Grants privileges to Data API roles by default, exposing new tables. We recommend disabling this to control access manually."
>
<FormControl>
<div>
diff --git a/apps/studio/hooks/misc/useDataApiRevokeOnCreateDefault.ts b/apps/studio/hooks/misc/useDataApiRevokeOnCreateDefault.ts
index 29f589ee6db..077d63e2308 100644
--- a/apps/studio/hooks/misc/useDataApiRevokeOnCreateDefault.ts
+++ b/apps/studio/hooks/misc/useDataApiRevokeOnCreateDefault.ts
@@ -5,7 +5,7 @@ import { IS_TEST_ENV } from '@/lib/constants'
import { useTrack } from '@/lib/telemetry/track'
/**
- * Controls the default state of the "Automatically expose new tables and functions"
+ * Controls the default state of the "Automatically expose new tables"
* checkbox at project creation. When the flag is on, the checkbox defaults
* to unchecked (i.e. revoke SQL runs). When off/absent, the checkbox defaults
* to checked (current behaviour — default grants remain).
diff --git a/apps/studio/pages/integrations/vercel/[slug]/deploy-button/new-project.tsx b/apps/studio/pages/integrations/vercel/[slug]/deploy-button/new-project.tsx
index 6565696c7eb..dad6d3c07fa 100644
--- a/apps/studio/pages/integrations/vercel/[slug]/deploy-button/new-project.tsx
+++ b/apps/studio/pages/integrations/vercel/[slug]/deploy-button/new-project.tsx
@@ -356,11 +356,11 @@ const CreateProject = () => {
htmlFor="dataApiDefaultPrivileges"
className="text-sm text-foreground-light flex items-center space-x-2 leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
>
- Automatically expose new tables and functions
+ Automatically expose new tables
</label>
<p className="text-sm text-foreground-muted">
- Grants privileges to Data API roles by default, exposing new tables and functions. We
- recommend disabling this to control access manually.
+ Grants privileges to Data API roles by default, exposing new tables. We recommend
+ disabling this to control access manually.
</p>
</div>
</div>