@ztimson/utils 0.27.18 → 0.27.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -2312,7 +2312,7 @@ ${opts.message || this.desc}`;
2312
2312
  };
2313
2313
  const evaluate = (code, data2, fatal = true) => {
2314
2314
  try {
2315
- return Function("data", `Object.assign(this, data); return ${code};`)(data2);
2315
+ return Function("data", `with(data) { return ${code}; }`)(data2);
2316
2316
  } catch {
2317
2317
  if (fatal) throw new TemplateError(`Failed to evaluate: ${code}`);
2318
2318
  else return false;