feat: finalize ticket merging and speaker-aware imports

This commit is contained in:
Lago committed 2026-10-10 13:28:18 +02:00
1 parent 648daa0794
commit 4e71e9b797
35 files changed
+1772 -348

No files matched your search

@@ -0,0 +1,19 @@
create or replace function public.can_request_admin_magic_link(p_email text)
returns boolean
language sql stable security definer
set search_path = ''
as $$
select exists (
select 1
from public.contacts as contact
where contact.email = lower(btrim(p_email))
and (contact.is_admin or contact.email like '%@appe.at')
and exists (
select 1 from auth.users as auth_user
where auth_user.email = contact.email
)
);
$$;
revoke all on function public.can_request_admin_magic_link(text) from public;
grant execute on function public.can_request_admin_magic_link(text) to anon, authenticated;