line_push/.nuxt/dist/client/e440647.js
2022-07-21 03:28:35 +00:00

1 line
1.0 KiB
JavaScript

(window.webpackJsonp=window.webpackJsonp||[]).push([[5],{301:function(e,r,t){"use strict";t.r(r);var n=t(15),o=(t(65),t(14),"https://api.contree.io/profile");r.default={template:"<p>OK</p>",middleware:function(e){return Object(n.a)(regeneratorRuntime.mark((function r(){var t,n,data,c,d,f,w,x;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return t=e.req,e.error,n=e.$axios,e.redirect,r.next=3,new Promise((function(e){var body="";t.on("data",(function(data){body+=data})),t.on("end",(function(){e(JSON.parse(body))}))}));case 3:return data=r.sent,c=data.LINEUserID=data.LINEUserID||"test",r.next=7,n.get(o,{params:{LINEUserID:c}});case 7:if(d=r.sent,f=data.VerifyNUM,w=data.VerifySys,!(d.data.length>0)){r.next=16;break}return x=d.data[0].id,r.next=14,n.patch("".concat(o,"/").concat(x),data);case 14:r.next=18;break;case 16:return r.next=18,n.post(o,data);case 18:return r.next=20,n.get("https://nodered.contree.io/contree_push",{params:{userid:c,Verify:f,VerifySys:w}});case 20:case"end":return r.stop()}}),r)})))()}}}}]);