Fork me on GitHub
a Sensio Labs Product

I ate three cookies 🍪 (v3.40.2) edition

Rule not_operator_with_space

Logical NOT operators (!) should have leading and trailing whitespaces.

Examples

Example #1

--- Original
+++ New
 <?php

-if (!$bar) {
+if ( ! $bar) {
     echo "Help!";
 }

Source class

PhpCsFixer\Fixer\Operator\NotOperatorWithSpaceFixer