import { AccessRulesForm } from '@/components/settings/access-rules-form';
import { listAccessRules } from '@/lib/access-rules';

interface AccessPageProps {
  params: Promise<{ guildId: string }>;
}

export default async function GuildAccessPage({ params }: AccessPageProps) {
  const { guildId } = await params;
  const rules = await listAccessRules(guildId);

  return <AccessRulesForm guildId={guildId} initialRules={rules} />;
}
