Exception: Serialization of 'Closure' is not allowed in serialize()

Created on 28 August 2025, 4 days ago

Since updating to 1.0.3 we are seeing fatal errors when updating/creating users. (1.0.2 works fine)
We are running Drupal core 11.1.8

Exception: Serialization of 'Closure' is not allowed in serialize() 

This error only occurs when we add an image field, using the media library widget to the user. (might be other use cases, don't know)

We "fixed" the error by commenting line 59 in FormHooks.php:

        $form['actions']['resend_register_mail']['#submit'][] = [$this, 'submitForm'];

This causes the module to not work anymore though, so not an actual solution...

Related to: https://www.drupal.org/project/resend_register_mail/issues/3519847 📌 Support OOP hooks Active

🐛 Bug report
Status

Active

Version

1.0

Component

Code

Created by

🇧🇪Belgium weseze

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024