MCPcopy Create free account
hub / github.com/Moli-X/Resources / getValue

Function getValue

Script/Parser.js:200–206  ·  view source on GitHub ↗
(fn, defaultVaule)

Source from the content-addressed store, hash-verified

198
199//避免json undefined错误的 函数
200const getValue = (fn, defaultVaule) => {
201 try {
202 return fn();
203 } catch (error) {
204 return defaultVaule;
205 }
206};
207
208var type0=""
209//flag=1,2,3分别为 server、rewrite、rule 类型

Callers 1

CV2QXFunction · 0.85

Calls 1

fnFunction · 0.70

Tested by

no test coverage detected