-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathXanaduModule.js
1 lines (1 loc) · 3.15 KB
/
XanaduModule.js
1
let modulFUNCxan=(u,r,l)=>{let E=(r,t)=>{"<br />C.A.C".replace(/<br\s*\/?>/gi,"\n").replace(/\\n /gi,"\n\t");var e="XanaduSoncikis_"+(l.isBrowser()?"browser":"node");return{urls:l.GetValiumOptimized(t,"url"),[e]:t}};return{XanaduForserver:async(r,t,e)=>{t=await l.newFormData(t,e);return{url:r,FetchSendOptions:{method:"POST",body:t,headers:{"x-nerden":"x-server FETCH@action : "+r}},AxiosSendData:t,AxiosSendOptions:{method:"POST",headers:{"x-nerden":"x-server AXIOS@action : "+r}}}},XanaduForclient:r=>{var t=new FormData(r),r=r.action;return{url:r,FetchSendOptions:{method:"POST",body:t,headers:{"x-nerden":"x-client FETCH@action : "+r}},AxiosSendData:t,AxiosSendOptions:{method:"POST",headers:{"x-nerden":"x-client AXIOS@action : "+r}}}},Xanadu:(r,t,e,s,a,n)=>{let o={SERVER:{thenResult:{},catchError:{}}},c="isBrowser : "+l.isBrowser(),i={};return("axios"==r?(n="#Axios# Bekleniyor... ",u.post(t,s,a).then(async r=>{n=c+"<br />",i=r?.data,o.SERVER.thenResult.statusText=r?.statusText,o.SERVER.thenResult.status=r?.status,o.SERVER.thenResult.serviceResultData=r?.data,n=(n=200==i?.status?n+"axios.than =1=> "+JSON.stringify(i,null,4)+"<br />bitti.":n+"axios.than =2=> "+JSON.stringify(i,null,4)+"<br />bitti.")+"<br />res_json.status: "+i?.status+"<br />serviceResult.status: "+r?.status}).catch(r=>{n=c+"<br />",o.SERVER.catchError.neoldu=" -axios.catch Biseyler yanlis gitti ! (Server down olmuş olabilir)",o.SERVER.catchError.url=r?.config?.url,o.SERVER.catchError=r,o.SERVER.catchError.code=r?.code,o.SERVER.catchError.message=r?.message,o.SERVER.catchError.stack=r?.stack,o.SERVER.catchError.res_json=JSON.stringify(i,null,4),n=n+o.SERVER.catchError.neoldu+"<br /> =1=> url : "+r?.config?.url+"<br /> =2=> catchError : "+r+"<br /> =3=> code : "+r?.code+"<br /> =4=> message : "+r?.message+"<br /> =5=> stack : "+r?.stack+"<br /> =6=> res_json : "+JSON.stringify(i,null,4)+"<br />"})):(n="#Fetch# Bekleniyor... ",fetch(t,e).then(async r=>{n=c+"<br />",i=await r.json(),o.SERVER.thenResult.statusText=r?.statusText,o.SERVER.thenResult.status=r?.status,o.SERVER.thenResult.serviceResultData=i,n=(n=200==i?.status?n+"fetch.than =1=> "+JSON.stringify(i,null,4)+"<br />bitti.":n+"fetch.than =2=> "+JSON.stringify(i,null,4)+"<br />bitti.")+"<br />res_json.status: "+i?.status+"<br />serviceResult.status: "+r?.status}).catch(r=>{n=c+"<br />",o.SERVER.catchError.neoldu=" -fetch.catch Biseyler yanlis gitti ! (Server down olmuş olabilir)",o.SERVER.catchError.url=r?.config?.url,o.SERVER.catchError=r,o.SERVER.catchError.code=r?.code,o.SERVER.catchError.message=r?.message,o.SERVER.catchError.stack=r?.stack,o.SERVER.catchError.res_json=JSON.stringify(i,null,4),n=n+o.SERVER.catchError.neoldu+"<br /> =1=> url : "+r?.config?.url+"<br /> =2=> catchError : "+r+"<br /> =3=> code : "+r?.code+"<br /> =4=> message : "+r?.message+"<br /> =5=> stack : "+r?.stack+"<br /> =6=> res_json : "+JSON.stringify(i,null,4)+"<br />"}))).then(()=>E(0,o))}}};((r,t)=>{"function"==typeof define&&define.amd?define(["axios","fs"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("axios"),require("fs")):r.XanaduModule=t(r.axios,r.fs,r.MandrakeModule)})("undefined"!=typeof window?window:this,modulFUNCxan);