WI: exclude characterFilter fields from new entry template

12a54d901ecca773b70d47faa7f932f30f91b746

Cohee <18619528+Cohee1207@users.noreply.github.com>

1 files changed, +5 -5Showing whitespace changes
public/scripts/world-info.js+5 -5
@@ -3608,7 +3608,7 @@ export async function deleteWorldInfoEntry(data, uid, { silent = false } = {}) {
36083608 *
36093609 * Use `newEntryTemplate` if you just need the template that contains default values
36103610 *
36113611 * @type {{[key: string]: { default: any, type: string, excludeFromTemplate?: boolean }}}
36123612 */
36133613export const newWorldInfoEntryDefinition = {
36143614 key: { default: [], type: 'array' },
@@ -3647,13 +3647,13 @@ export const newWorldInfoEntryDefinition = {
36473647 sticky: { default: null, type: 'number?' },
36483648 cooldown: { default: null, type: 'number?' },
36493649 delay: { default: null, type: 'number?' },
36503650 characterFilterNames: { default: [], type: 'array', excludeFromTemplate: true },
36513651 characterFilterTags: { default: [], type: 'array', excludeFromTemplate: true },
36523652 characterFilterExclude: { default: false, type: 'boolean', excludeFromTemplate: true },
36533653};
36543654
36553655export const newWorldInfoEntryTemplate = Object.fromEntries(
36563656 Object.entries(newWorldInfoEntryDefinition).filter(([_, value]) => !value.excludeFromTemplate).map(([key, value]) => [key, value.default]),
36573657);
36583658
36593659/**