// REQ0006
import { COL_QUIZ_LP_CATEGORIES } from '@/constants';

import { pb } from '@/lib/pb';

export default async function getHiddenQuizLPCategoriesCount(): Promise<number> {
  try {
    const result = await pb.collection(COL_QUIZ_LP_CATEGORIES).getList(1, 9999, { filter: 'visible = "hidden"' });
    const { totalItems: count } = result;
    return count;
  } catch (error) {
    return 0;
  }
}
