"use strict";(()=>{var e={};e.id=6422,e.ids=[6422],e.modules={76102:e=>{e.exports=require("@moduletrace/datasquirel/dist/client")},39383:e=>{e.exports=require("@moduletrace/datasquirel/dist/package-shared/actions/users/user-auth")},65967:e=>{e.exports=require("@moduletrace/datasquirel/dist/package-shared/utils/ejson")},93726:e=>{e.exports=require("@moduletrace/datasquirel/dist/package-shared/utils/numberfy")},30889:e=>{e.exports=require("@moduletrace/datasquirel/dist/package-shared/utils/slugify")},75600:e=>{e.exports=require("next/dist/compiled/next-server/pages-api.runtime.prod.js")},29021:e=>{e.exports=require("fs")},33873:e=>{e.exports=require("path")},96762:(e,r)=>{Object.defineProperty(r,"M",{enumerable:!0,get:function(){return function e(r,s){return s in r?r[s]:"then"in r&&"function"==typeof r.then?r.then(r=>e(r,s)):"function"==typeof r&&"default"===s?r:void 0}}})},49860:(e,r,s)=>{s.r(r),s.d(r,{config:()=>p,default:()=>S,routeModule:()=>E});var t={};s.r(t),s.d(t,{default:()=>l});var n=s(89947),i=s(2706),a=s(96762),u=s(29021),o=s.n(u),d=s(33873),c=s.n(d),_=s(69842);async function l(e,r){if("GET"!==e.method)return r.json({msg:"Failed!"});let{user:s}=await (0,_.A)(e,r);if(!s)return r.json({success:!1,msg:"Unauthorized"});let{name:t,folder:n}=e.query,i=process.env.DSQL_STATIC_SERVER_DIR;if(!i)return console.log("Static File ENV not Found!"),r.json({success:!1,msg:"No Static Path!"});let a=c().join(i,`images/user-images/user-${s.id}/${n?n+"/":""}`),u=o().existsSync(a+t);r.json({success:u})}let S=(0,a.M)(t,"default"),p=(0,a.M)(t,"config"),E=new n.PagesAPIRouteModule({definition:{kind:i.A.PAGES_API,page:"/api/checkExistingFolder",pathname:"/api/checkExistingFolder",bundlePath:"",filename:""},userland:t})},55153:(e,r,s)=>{s.d(r,{On:()=>n.a,_n:()=>a}),s(76102);var t=s(65967),n=s.n(t);s(30889);var i=s(93726);let a=s.n(i)()},69842:(e,r,s)=>{s.d(r,{A:()=>a});var t=s(39383),n=s.n(t),i=s(55153);async function a(e,r,s,t){let a=n()({req:e,level:s?"deep":void 0}),u={DSQL_REMOTE_SQL_HOST:process.env.DSQL_REMOTE_SQL_HOST,DSQL_SU_USER_ID:process.env.DSQL_SU_USER_ID,DSQL_HOST_ENV:process.env.DSQL_HOST_ENV,DSQL_HOST:process.env.DSQL_HOST,DSQL_STATIC_HOST:process.env.DSQL_STATIC_HOST,DSQL_GOOGLE_CLIENT_ID:process.env.DSQL_GOOGLE_CLIENT_ID,DSQL_TINY_MCE_API_KEY:process.env.DSQL_TINY_MCE_API_KEY};return t&&a.payload?.id&&(0,i._n)(process.env.DSQL_SU_USER_ID)!==a.payload.id?{user:null,appData:u}:{user:a.payload,appData:u}}},2706:(e,r)=>{Object.defineProperty(r,"A",{enumerable:!0,get:function(){return s}});var s=function(e){return e.PAGES="PAGES",e.PAGES_API="PAGES_API",e.APP_PAGE="APP_PAGE",e.APP_ROUTE="APP_ROUTE",e.IMAGE="IMAGE",e}({})},89947:(e,r,s)=>{e.exports=s(75600)}};var r=require("../../webpack-api-runtime.js");r.C(e);var s=r(r.s=49860);module.exports=s})();