Before that, the php file tried to evaluate a ‘zero’, of course this is not possible. Zero is not defined. If (isset ()) checks whether changelogURL is not ‘zero’ and if this is true it writes the result to the log.
I got a new error messages after applying this change:
Use of undefined constant ‘changelogURL’ - assumed ‘‘changelogURL’’ (this will throw an Error in a future version of PHP) at /var/www/html/core/Controller/WhatsNewController.php#94
Use of undefined constant ‘version’ - assumed ‘‘version’’ (this will throw an Error in a future version of PHP) at /var/www/html/core/Controller/WhatsNewController.php#92
Use of undefined constant ‘product’ - assumed ‘‘product’’ (this will throw an Error in a future version of PHP) at /var/www/html/core/Controller/WhatsNewController.php#91
Update: I change ’ to " and didn’t get the error message when restarted the docker container. Maybe the solution? (My knowledge of PHP is like 1 on a scale 1-100)
That was probably due to the formatting of the text in the code box from @enis45 . For anyone else having the issue benis had, here the copy&paste friendly version:
EDIT: It seems that people already made the developers aware of this on Github (https://github.com/nextcloud/server/issues/19490) and that it will be fixed with the next update. For the time being the above code fixes it temporary.