This comes from your database server, not the script. Sngine 5 requires MySQL 8.0+ (or MariaDB 10.6+), and an older MySQL version does not support a query the newsfeed uses. Ask your host to upgrade MySQL to 8.0. Your data will not be affected, and the newsfeed will work once it is upgraded.