Fix plugin filter test

This commit is contained in:
Chocobozzz 2022-07-13 11:26:00 +02:00
parent f7ce623db1
commit da5f46487f
No known key found for this signature in database
GPG Key ID: 583A612D890159BE

View File

@ -192,7 +192,7 @@ async function register ({ registerHook, registerSetting, settingsManager, stora
registerHook({
target: 'filter:api.user.signup.allowed.result',
handler: (result, params) => {
if (params && params.body.email.includes('jma')) {
if (params && params.body && params.body.email && params.body.email.includes('jma')) {
return { allowed: false, errorMessage: 'No jma' }
}