Skip to content

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

Removed deprecated function calls

Andrew Smith2cc0072f7de6
diff --git a/apps/reference/docs/learn/auth-deep-dive/policies.md b/apps/reference/docs/learn/auth-deep-dive/policies.md
index 7533479c97c..0a63e5215a2 100644
--- a/apps/reference/docs/learn/auth-deep-dive/policies.md
+++ b/apps/reference/docs/learn/auth-deep-dive/policies.md
@@ -141,11 +141,11 @@ Once you get the hang of policies you can start to get a little bit fancy. Let's
create policy "Only Blizzard staff can update leaderboard"
on my_scores
for update using (
- right(auth.email(), 13) = '@blizzard.com'
+ right(auth.jwt()->>'email', 13) = '@blizzard.com'
);
```
-Supabase comes with three built-in helper functions: `auth.email()`, `auth.uid()` and `auth.role()`.
+Supabase comes with two built-in helper functions: `auth.uid()` and `auth.jwt()`.
See the full PostgreSQL policy docs here: [https://www.postgresql.org/docs/12/sql-createpolicy.html](https://www.postgresql.org/docs/12/sql-createpolicy.html)