Fix forgotten parameter 'key' in 'cleanHtml'

This commit is contained in:
Wolfgang Huß 2022-06-28 09:39:54 +02:00
parent f92cec3749
commit 5dd969c372
2 changed files with 2 additions and 2 deletions

View File

@ -56,7 +56,7 @@ const standardSanitizeHtmlOptions = {
},
}
export function cleanHtml(dirty, sanitizeHtmlOptions = standardSanitizeHtmlOptions) {
export function cleanHtml(dirty, _key, sanitizeHtmlOptions = standardSanitizeHtmlOptions) {
if (!dirty) {
return dirty
}

View File

@ -26,7 +26,7 @@ if (!hasEmailConfig) {
console.log('Content:')
// eslint-disable-next-line no-console
console.log(
cleanHtml(templateArgs.html, {
cleanHtml(templateArgs.html, 'dummyKey', {
allowedTags: ['a'],
allowedAttributes: { a: ['href'] },
}).replace(/&/g, '&'),