"use strict";(()=>{var e={};e.id=5862,e.ids=[5862],e.modules={53524:e=>{e.exports=require("@prisma/client")},20399:e=>{e.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},30517:e=>{e.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},40793:(e,t,r)=>{r.r(t),r.d(t,{originalPathname:()=>v,patchFetch:()=>x,requestAsyncStorage:()=>l,routeModule:()=>d,serverHooks:()=>h,staticGenerationAsyncStorage:()=>m});var a={};r.r(a),r.d(a,{GET:()=>p,dynamic:()=>c});var s=r(49303),n=r(88716),o=r(60670),i=r(87070),u=r(72331);let c="force-dynamic";async function p(){try{let e=(await u._.chatMessage.findMany({where:{createdAt:{gte:new Date(Date.now()-864e5)}},distinct:["userId"],select:{user:{select:{id:!0,username:!0,vipLevel:!0,role:!0,image:!0}}},orderBy:{createdAt:"desc"},take:50})).map(e=>e.user);return i.NextResponse.json(e)}catch(e){return console.error("Fetch active users error:",e),i.NextResponse.json({error:"Failed to fetch active users"},{status:500})}}let d=new s.AppRouteRouteModule({definition:{kind:n.x.APP_ROUTE,page:"/api/chat/users/route",pathname:"/api/chat/users",filename:"route",bundlePath:"app/api/chat/users/route"},resolvedPagePath:"C:\\Users\\MSI\\Downloads\\film\\app\\api\\chat\\users\\route.ts",nextConfigOutput:"standalone",userland:a}),{requestAsyncStorage:l,staticGenerationAsyncStorage:m,serverHooks:h}=d,v="/api/chat/users/route";function x(){return(0,o.patchFetch)({serverHooks:h,staticGenerationAsyncStorage:m})}},72331:(e,t,r)=>{r.d(t,{_:()=>s});var a=r(53524);let s=global.prisma||new a.PrismaClient}};var t=require("../../../../webpack-runtime.js");t.C(e);var r=e=>t(t.s=e),a=t.X(0,[8948,5972],()=>r(40793));module.exports=a})();