[Bug]: `hexo s` 命令报错,`Template render error: (unknown path) TypeError: str must be a string!`
Author: chunxiao01Created Sep 23, 2026Updated Sep 23, 2026
使用的 Butterfly 版本? | What version of Butterfly are you using?
5.7.0
是否修改過主題文件? | Has the theme files been modified?
是 (Yes)
使用的瀏覽器? | What browser are you using?
Chrome
使用的系統? | What operating system are you using?
Windows
依賴插件 | Package dependencies information
无問題描述 | Describe the bug
一、问题示例:
{% flink %}
- class_name: 友情鏈接
class_desc: 那些人,那些事
link_list:
- name: CrazyWong
link: https://crazywong.com
avatar: https://crazywong.com/img/avatar.png
descr: 123456
- name: Hexo
link: https://hexo.io/zh-tw/
avatar: https://d33wubrfki0l68.cloudfront.net/6657ba50e702d84afb32fe846bed54fba1a77add/827ae/logo.svg
descr: 123456
{% endflink %}二、分析:
当descr为非字符串时,导致hexo s报错。
问题定位于/butterfly/scripts/tag/flink.js中使用escapeHTML作为字符串转换,导致报错。
出現問題的網站 | Website with the issue
Source: jerryc127/hexo-theme-butterfly