@zenweb/template 3.2.0 → 3.2.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # Changelog
2
2
 
3
+ ## [3.2.1] - 2023-4-26
4
+ - fix: 使用 ctx.fail 时错误已设置 template 被至空问题
5
+
3
6
  ## [3.2.0] - 2023-4-3
4
7
  - 不再集成内置引擎,使用独立包
5
8
 
package/dist/render.js CHANGED
@@ -41,7 +41,7 @@ class TemplateRender {
41
41
  if (data instanceof result_1.ResultFail) {
42
42
  data = { fail: data };
43
43
  if (opt.failTemplate !== false) {
44
- template = opt.failTemplate || this._option.failTemplate;
44
+ template = opt.failTemplate || this._option.failTemplate || template;
45
45
  }
46
46
  }
47
47
  if (!template) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zenweb/template",
3
- "version": "3.2.0",
3
+ "version": "3.2.1",
4
4
  "description": "zenweb template render module",
5
5
  "exports": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",