Skip to content

Commit

Permalink
Merge pull request #189 from h8570rg/fix/policy
Browse files Browse the repository at this point in the history
fix: policy
  • Loading branch information
h8570rg authored Sep 17, 2024
2 parents faf3259 + eca11ae commit e2d01a1
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions supabase/migrations/20240917134035_local.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
drop policy "Authenticated users can select matches" on "public"."matches";

create policy "Authenticated users can select matches"
on "public"."matches"
as permissive
for select
to authenticated
using (((EXISTS ( SELECT 1
FROM match_players
WHERE ((match_players.match_id = matches.id) AND (match_players.player_id = auth.uid())))) OR (created_by = auth.uid())));



0 comments on commit e2d01a1

Please sign in to comment.