Özgün çalışan dosya
reference/delete-policy.sql
Kodlardaki adlar ve çalışan örnek sayfalardaki metinler özgün halleriyle korunmuştur. Ders ve dosya açıklamaları bunları Türkçe olarak açıklar.
-- Apply in the disposable project after the starter upload/read policies.
create policy "delete own avatar" on storage.objects for delete to authenticated
using (bucket_id='avatars' and (storage.foldername(name))[1]=auth.uid()::text);
-- Test a crafted cross-owner request too; client-side checks alone are not protection.