mybb / mybb2

The repository for the MyBB 2 forum software. Not to be used on live boards.
https://www.mybb.com
BSD 3-Clause "New" or "Revised" License
109 stars 45 forks source link

Run sniffer #97

Closed JN-Jones closed 9 years ago

JN-Jones commented 9 years ago

This are the changes CodeSniffer did automatically with our standard. I've run php phpcbf.phar --standard=MyBB2 ./app ./bootstrap ./config ./database ./resources ./tests so the public directory isn't changed as I'm not yet sure which files need to be checker there. Also the summary still show A TOTAL OF 73 ERRORS AND 45 WARNINGS WERE FOUND IN 86 FILES which can't be fixed automatically. Still need to look at them as not all should be fixed at this point (eg migrations and tests aren't namespaced).

Note that this has the potential to destroy every PR that isn't merged atm. And the conflicts will be pretty hard to solve.

JN-Jones commented 9 years ago

Still 73 errors and 45 warnings; 56/7 of them in database files (migrations/seeds)

JN-Jones commented 9 years ago

How do we want to handle Presenter methods? According to PSR-2 they should be camel case but as they're often used as attributes (eg num_votes) I'm not sure whether this should be changed.

JN-Jones commented 9 years ago

Thousands of changes later this should be finished. Note that I haven't tested the changes yet as most of them were automatic changes.