Fixed Warning: "continue" targeting switch is equivalent to "break".

Rasmus Vind

Well-known member
Affected version
2.0.10
Running 2.0.10.

I am getting this:
Code:
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 458
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 459
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 462
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 463
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 466
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 467
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 470
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 471
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 472
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 473
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 476
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 477
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 480
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 481
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 484
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 485
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 486
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 487
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 490
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 493
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 496
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 504
Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /var/www/html/src/XF/Language.php on line 525
on every page of my XF install:
Code:
PHP 7.3.0alpha4 (cli) (built: Jul 25 2018 11:42:36) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.0-dev, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.3.0alpha4, Copyright (c) 1999-2018, by Zend Technologies

Simply by replacing 'continue' with 'break' makes my site work just fine.

By googling this error it seems to be something to do with very recent PHP 7 versions.
 
Back
Top Bottom