Announcement

Symphony's issue tracker has been moved to Github.

Issues are displayed here for reference only and cannot be created or edited.

Browse

Closed#494: Errors in the logs, caused by language class

Symphony 2.2beta2 (installed from ZIP) throws lots of errors in the logs like these:

2011/01/17 20:17 > Warning: 2 - Invalid argument supplied for foreach() in file /Users/me/Sites/dev/me/s22beta2/symphony/lib/toolkit/class.lang.php on line 325
2011/01/17 20:17 > Warning: 2 - Invalid argument supplied for foreach() in file /Users/me/Sites/dev/me/s22beta2/symphony/lib/toolkit/class.lang.php on line 336

There are two loops of:

foreach($extensions as $extension) {

I don’t know why there are two, could be merged into one. There needs to be a check that $extensions is an array first.

Fixed/Optimised in this commit

While it’s correct that there shouldn’t be two foreach loops over the $extensions object, the fix is wrong and actually breaks language management.

This should really solve the problem: https://github.com/nilshoerrmann/symphony-2/commit/76d465c93c4cc270e7e4efa41df10cbf5cb6462e

I’ll send a new pull request.

This issue is closed.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details