PHPStorm switch statement 'break' indenting

coding-style, indentation, phpstorm

Solution

You can change this default behavior in

settings | Editor | Code Style | PHP | Wrapping and Braces

uncheck indent 'break' from 'case' option

Problem

PHPStorm is a very nice IDE, but it does one thing that annoys me. I (and my team) write our switch statements like so: ``` switch ($foo) { case 'a' : // some code break; } ``` PHPStorm auto-corrects this to be ``` switch ($foo) { case 'a' : // some code break; } ``` Note that the `break` is indented along with the code. I don't want this to happen. I've looked in the code style section, but the only option for switches is to indent the case branches. Does anyone know how stop PHPStorm from doing this?

Original source