php - Strange PHPCS error message -


i have following snippet in php class:

$returnarray = array(); while($row = mysql_fetch_assoc($rhandle)) {     $returnarray[] = $row; } 

phpcs complains 'while' line:

 161 | error   | expected "while (...) {\n"; found "while(...){\n" 

the problem cs (in case) expects space after while. need write code this:

while ($row = mysql_fetch_assoc($rhandle)) { } 

edit: also, see cs reporting missing space between ) , { when closing while, think fixed when posting question :)


Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -