"use strict";(()=>{vare={};e.id=5905,e.ids=[5905],e.modules={75600:e=>{e.exports=require("next/dist/compiled/next-server/pages-api.runtime.prod.js")},9973:e=>{e.exports=require("serverless-mysql")},79428:e=>{e.exports=require("buffer")},55511:e=>{e.exports=require("crypto")},29021:e=>{e.exports=require("fs")},81630:e=>{e.exports=require("http")},33873:e=>{e.exports=require("path")},96762:(e,r)=>{Object.defineProperty(r,"M",{enumerable:!0,get:function(){returnfunctione(r,t){returntinr?r[t]:"then"inr&&"function"==typeofr.then?r.then(r=>e(r,t)):"function"==typeofr&&"default"===t?r:void0}}})},62347:(e,r,t)=>{t.r(r),t.d(r,{config:()=>_,default:()=>d,routeModule:()=>S});vars={};t.r(s),t.d(s,{default:()=>p});varn=t(89947),a=t(2706),o=t(96762),c=t(57638),l=t.n(c);t(48225);vari=t(19131),u=t.n(i);asyncfunctionp(e,r){if("GET"!==e.method)returnr.json({success:!1,msg:"Wrong Method"});lett=awaitu()(e);if(!t?.logged_in_status)returnr.json({success:!1,log:"No Logs"});let{database:s}=e.query;try{lete=awaitl()({database:"string"==typeofs?s:"",queryString:`SHOW TABLES FROM ${s}`});if(!e)returnr.json({success:!1,msg:"Query Failed!"});r.json({success:!0,tables:e.map(e=>Object.values(e)[0])})}catch(e){console.log(e.message),r.json({success:!1})}}t(29021);letd=(0,o.M)(s,"default"),_=(0,o.M)(s,"config"),S=newn.PagesAPIRouteModule({definition:{kind:a.A.PAGES_API,page:"/api/admin/getTablesForUserDatabase",pathname:"/api/admin/getTablesForUserDatabase",bundlePath:"",filename:""},userland:s})},19131:(e,r,t)=>{let{IncomingMessage:s}=t(81630),n=t(72835),a=t(31341);e.exports=asyncfunction(e){let{keyCookieName:r,csrfCookieName:t}=a(),s=`${r}_su`;if(!e.cookies?.[s])returnconsole.log("No auth key cookie found"),null;leto=n({encryptedString:e.cookies[s]});if(!o)returnconsole.log("No user payload found"),null;letc=JSON.parse(o);returnc.password!==process.env.DSQL_USER_KEY?(console.log("Invalid password"),null):c.authKey!==process.env.DSQL_SPECIAL_KEY?(console.log("Invalid auth key"),null):c}},31341:e=>{e.exports=function(){lete=process.env.DSQL_COOKIES_PREFIX||"dsql_";return{keyCookieName:e+(process.env.DSQL_COOKIES_KEY_NAME||"key"),csrfCookieName:e+(process.env.DSQL_COOKIES_CSRF_NAME||"csrf")}}},30003:e=>{e.exports=/^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/},6061:(e,r,t)=>{lets=t(72835),n=t(30003);e.exports=asyncfunction({unparsedResults:e,tableSchema:r}){lett=[];try{for(leta=0;a<e.length;a++){leto=e[a],c=Object.keys(o);for(lete=0;e<c.length;e++){lett=c[e],a=r?.fields[e];if(t?.match(n))continue;letl=o[t];("number"==typeofl||l)&&a?.encrypted&&l?.match(/./)&&(o[t]=s({encryptedString:l}))}t.push(o)}returnt}catch(r){returnconsole.log("ERROR in parseDbResults Function =>",r.message),e}}},48225:(e,r,t)=>{lets=t(29021),{IncomingMessage:n}=t(81630);e.exports=asyncfunction({user:e,message:r,component:t,noMail:n,req:a}){leto=newDate,c=(()=>{if(!a)returnnull;try{lete=a.headers["x-forwarded-for"],r=a.headers["x-real-ip"],t=a.headers["cf-connecting-ip"],s=Array.isArray(e)?e[0]:e?.split(",")[0],n=t||s||r||a.socket.remoteAddress;if(!n)returnnull;returnString(n)}catch(e){returnnull}})();try{letn=`🚀 SERVER ERROR ===========================