drop function if exists public.has_access_to_team;

create function public.has_access_to_team(user_ids uuid, team_id uuid)
 returns boolean
 language plpgsql
 security definer
as $function$
  declare
    has_access boolean;
    parent_id uuid;
  begin
  end;  
$function$;
