Make the file PSR2 standards

I have made the file PSR2 compliant according to [PHP-CS-Fixer](https://github.com/fabpot/PHP-CS-Fixer).

I have also made a few changes to the switches such as adding a new line between case's