Nextcloud crlon 'notes' errors logged "syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)
Please make a clear and concise description of what the bug is. Please note, that issues with the Android app have to be reported under https://github.com/stefan-niedermann/nextcloud-notes/issues and issues with Nextcloud's Text app have to be reported under https://github.com/nextcloud/text/issues .
Steps to reproduce
- Install notes
- Allow nextcloud cron job to run
Expected behaviour
Notes works without logging errors
Actual behaviour
Notes appears to work fine, but logs this error every time the nextcloud cron runs, parsing installed apps.
"syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)"
Screenshots
N/A
Server
Please complete the following information.
- Notes app version: 4.5.1
- Nextcloud version: 23.0.7/23.0.9
- OS: Debian 10
- Web server: nginx
- PHP version: 7.4-fpm
- Database: mariadb
Nextcloud configuration:
Client
Please complete the following information.
- Browser (incl. version):
- OS:
Log files
{"reqId":"XXXXXXXXXX","level":4,"time":"2022-09-16T21:50:01+01:00","remoteAddr":"","user":"--","app":"notes","method":"","url":"--","message":"Error during app loading: syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)","userAgent":"--","version":"23.0.9.1","exception":{"Exception":"ParseError","Message":"syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)","Code":0,"Trace":[{"file":"/var/www/nextcloud/lib/composer/composer/ClassLoader.php","line":428,"function":"Composer\Autoload\includeFile","args":["/var/www/nextcloud/apps/notes/lib//AppInfo/Application.php"]},{"function":"loadClass","class":"Composer\Autoload\ClassLoader","type":"->","args":["OCA\Notes\AppInfo\Application"]},{"function":"spl_autoload_call","args":["OCA\Notes\AppInfo\Application"]},{"file":"/var/www/nextcloud/lib/private/AppFramework/Bootstrap/Coordinator.php","line":197,"function":"class_exists","args":["OCA\Notes\AppInfo\Application"]},{"file":"/var/www/nextcloud/lib/private/legacy/OC_App.php","line":172,"function":"isBootable","class":"OC\AppFramework\Bootstrap\Coordinator","type":"->","args":["notes"]},{"file":"/var/www/nextcloud/lib/private/legacy/OC_App.php","line":140,"function":"loadApp","class":"OC_App","type":"::","args":["notes"]},{"file":"/var/www/nextcloud/cron.php","line":55,"function":"loadApps","class":"OC_App","type":"::","args":[]}],"File":"/var/www/nextcloud/apps/notes/lib/AppInfo/Application.php","Line":15,"message":"Error during app loading: syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)","exception":[],"CustomMessage":"Error during app loading: syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)"},"id":"6324e193f0a5d"}