Code excepetion: AH01071: Got error 'PHP message: PHP Fatal error: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in... 😱

I’m getting this error:

AH01071: Got error 'PHP message: PHP Fatal error: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in public_html/modules/InboundEmail/InboundEmail.php:1845\nStack trace:\n#0

when you visit the user profile page and attempt to load e-mail settings:
Full error message here at Pastebin:

Anyone here experienced this before and maybe have clue on how to solve it?

We are currently using PHP verison 8.0.27

Thanks in advance.
Kind regards
AngryWarrior.

Its an incompatiblity of suite with php8
Either switch to php 7.4 or check which variable is passed to count() function and check whether the variable is countable using is_countable and then pass to count

Thanks for the reply.

Well even if we lower it again back to PHP 7.4.33 the settings doesn’t load properly anymore. it did however allow us to save settings in inbound accounts → admin → emails – inbound → etc…

Kind regards

The whole “mail account” tab is missing in our system even with PHP 7.4.33.

It should look like this:
image

But it looks like this:
image
which is kind of strange. :thinking:

Error message is still the same with the lower PHP version:
AH01071: Got error 'PHP message: PHP Warning: count(): Parameter must be an array or an object that implements Countable in public_html/modules/InboundEmail/InboundEmail.php on line 1845PHP message: PHP Warning: count(): Parameter must be an array or an object that implements Countable in public_html/modules/InboundEmail/InboundEmail.php on line 1845', referer: https://crm.tmcloud.work/index.php?module=Users&action=EditView&record=8b3ba8d1-f0e7-a0be-2dbf-5e3328ef8b86

The php ini error_reporting should be configured as follows

It is.
I even enabled debug in the config.php file and dev mode. But I cannot find any error so far that related to the personal email configuration manager. The only error I have seen so far related is was the one I previously above posted.

I’m right now out of ideas.
Could it help if we uploaded a fresh set of core files?

Did you upgrade your crm ?
In the 7.13.1 the mail accounts system has changed a lot with the introduction of oauth2 authentication providers for emails. I haven’t tested it personally but might be worth it looking at the suite demo to see if this button is supposed to be there or not

We upgrade every time there is a new release.
Currently we are running:
image

@pgr do you know anything about this?
Have the “Mail Accounts” tab been removed and moved somewhere elsewhere?

Thanks in advance! :facepunch:

Kind regards

Yes it has been moved. The updated docs are here:

You’ll find the missing inbound accounts configuration screens by visiting your profile and checking the left-hand menu.

1 Like

Thanks a bunch. It seems that they haven’t updated that section yet as it leads to a 404.


(https://docs.suitecrm.com/admin/user/introduction/managing-user-accounts)

Any chance you could guide me to where you now can find the moved “Mail Accounts” tab please @pgr?:smiley:

Thanks in advance!

it’s there in my previous post :point_up:

Move to a new posting…