Skip to main content
Topic: ERROR Administration Center Trying to access array offset on value of type bool (Read 671 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

ERROR Administration Center Trying to access array offset on value of type bool

Hi there,

- I have just installed my first ElkArte Community Software, it went smood as  :partying_face

All seems fine until I log into the Admin Center and get hit with this error message "Trying to access array offset on value of type bool" ,now, the strange part is that I can't acccess the Admin Center -or- Support & Credits without getting this error message but everything else is accessible.

Anyone got a clue about what's causing this?


Re: ERROR Administration Center Trying to access array offset on value of type bool

Reply #1

That is a:bug:thanks for all the details.

Change line 31 in Server.subs.php which currently has if (function_exists('sys_getloadavg')) to instead say if (function_exists('sys_getloadavg') && sys_getloadavg() !== false)

The problem is that function can return false, in which case trying to access it as an array throws an error.  The above should prevent that.
`