Can't edit email template

Hi,
with OJS 3.4.0.8
in Manage Emails page I can’t edit Sent to Review template. If i click on “edit” button nothing appens.

In server log I get the following error

AH01071: Got error ‘PHP message: Slim Application Error:\nType: TypeError\nMessage: PKP\emailTemplate\maps\Schema::summarize(): Argument #1 ($item) must be of type PKP\emailTemplate\EmailTemplate, null given, called in /SERVER_FOLDER/lib/pkp/classes/emailTemplate/maps/Schema.php on line 71\nFile:
/SERVER_FOLDER/lib/pkp/classes/emailTemplate/maps/Schema.php\nLine: 44\nTrace: #0
/SERVER_FOLDER/lib/pkp/classes/emailTemplate/maps/Schema.php(71): PKP\emailTemplate\maps\Schema->summarize()\n#1 [internal function]: PKP\emailTemplate\maps\Schema->PKP\emailTemplate\maps\{closure}()\n#2 /SERVER_FOLDER/lib/pkp/lib/vendor/laravel/framework/src/Illuminate/Collections/Arr.php(560): array_map()\n#3 /SERVER_FOLDER/lib/pkp/lib/vendor/laravel/framework/src/Illuminate/Collections/Collection.php(768): Illuminate\Support\Arr::map()\n#4
/SERVER_FOLDER/lib…’, referer: https://WEB_URL/index.php/FE/management/settings/manageEmails

Thank you,

Enzo

Hi @Enzo, it seems that one of the email templates is missing: EDITOR_DECISION_SEND_TO_EXTERNAL. It something I can’t reproduce. Is your OJS instance freshly installed from 3.4 or is upgraded from a previous version? If upgraded, can you specify the version it was upgraded from?

Hi, it is an upgraded version:

3.4.0.8 2025-11-11
3.3.0.20 2025-11-11
3.2.1.0 2025-11-11
2.4.8.3 2018-03-23

I founded this usefull article that helped me to find the solution.

I installed a clean and new version of 3.4.0.8 OJS and compared the followind DB tables:

  • email_templates_default_data

  • email_templates

  • email_templates_settings

So I noticed that email_templates where incomplete. Substituting the tree tables with the new ones everything is working correctly. I’ve lost the customized email templates but it is not a problem.

1 Like

Yes, that was the best solution. It likely that the data went missing between older upgrades.