mirror of
https://github.com/Litlyx/litlyx
synced 2025-12-10 07:48:37 +01:00
12 lines
309 B
TypeScript
12 lines
309 B
TypeScript
|
|
import { OnboardingModel } from '@schema/OnboardingSchema';
|
|
|
|
export default defineEventHandler(async event => {
|
|
|
|
const ctx = await getRequestContext(event, 'flag:allowAnonRegistered');
|
|
|
|
const exists = await OnboardingModel.exists({ user_id: ctx.user_id });
|
|
|
|
return { exists: exists != null }
|
|
|
|
}); |