Error 500 during saving email settings

We have a on premise environment that is running on SE Linux, PHP version 7.3.27 with mysql version 5.7.28. We upgraded the instance to the latest on premise version (10.0.4). All seems to be working as I would expect except one thing:

For some reason when I open a user profile ( users module ) we receive an error 500 and in the logs it states the following:

[Fri Apr 09 13:29:49.897344 2021] [php7:warn] [pid 32101] [client 10.116.11.8:52072] PHP Warning: Invalid argument supplied for foreach() in /appl/www/<sugarpath>/htdocs/modules/EmailMan/views/view.config.php on line 195, referer: https://<sugarpath>/index.php?module=Administration&action=index&bwcFrame=1

So I checked the e-mail settings and these are indeed not filled in. I tried to fill them in but when I try to save these settings I do get an 500 error again and get the following error in the apache error log:

[Fri Apr 09 13:30:18.695248 2021] [php7:error] [pid 8897] [client 10.116.11.8:52075] PHP Fatal error: Uncaught Error: Call to a member function populateFromPost() on null in /appl/www/<sugarpath>/htdocs/modules/EmailMan/controller.php:36\nStack trace:\n#0 /appl/www/<sugarpath>/htdocs/include/MVC/Controller/SugarController.php(448): EmailManController->action_Save()\n#1 /appl/www/<sugarpath>/htdocs/include/MVC/Controller/SugarController.php(421): SugarController->do_action()\n#2 /appl/www/<sugarpath>/htdocs/include/MVC/Controller/SugarController.php(396): SugarController->handle_action()\n#3 /appl/www/<sugarpath>/htdocs/include/MVC/Controller/SugarController.php(304): SugarController->process()\n#4 /appl/www/<sugarpath>/htdocs/include/MVC/SugarApplication.php(199): SugarController->execute()\n#5 /appl/www/<sugarpath>/htdocs/index.php(27): SugarApplication->execute()\n#6 {main}\n thrown in /appl/www/<sugarpath>/htdocs/modules/EmailMan/controller.php on line 36, referer: https://<sugarpath>/index.php?module=EmailMan&action=config

is there someone who noticed same behaviour during upgrades?

Parents
  • From modules/EmailMan/controller.php we have:

                $oe = $oe->getSystemMailerSettings();
                $oe->populateFromPost();
    

    I believe that the issue is at $oe->getSystemMailerSettings(), once this method returns null|OutboundEmail. It returns null if method retrieve from SugarBean returns null as well.

    So you need to debug the array returned by $this->getSystemMailData(); and conditions to SugarBean returns null in method retrieve.

    Regards

    André Lopes
    Lampada Global
    Skype: andre.lampada
Reply
  • From modules/EmailMan/controller.php we have:

                $oe = $oe->getSystemMailerSettings();
                $oe->populateFromPost();
    

    I believe that the issue is at $oe->getSystemMailerSettings(), once this method returns null|OutboundEmail. It returns null if method retrieve from SugarBean returns null as well.

    So you need to debug the array returned by $this->getSystemMailData(); and conditions to SugarBean returns null in method retrieve.

    Regards

    André Lopes
    Lampada Global
    Skype: andre.lampada
Children
No Data