Add missing Handlebars join helper for item sheet templates

Class and perk item sheets use {{join arr ", "}} to display array fields
but the helper was never registered.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Cal Corum 2025-12-16 14:46:20 -06:00
parent 06e0dc01c0
commit 607c65cffc

View File

@ -367,6 +367,12 @@ Hooks.once("init", () => {
const n = Number(num) || 0;
return n >= 0 ? `+${n}` : `${n}`;
});
// Join array elements with separator
Handlebars.registerHelper("join", (arr, separator) => {
if (!Array.isArray(arr)) return "";
return arr.join(separator);
});
});
/* -------------------------------------------- */