PSR for nested IF condition

355 views Asked by At

I am just to migrate my code in to PSR standard. I am not sure about how to write it inside nested condition. I am confused by line spacing. Can I use one line space after If condition ? Below is my example code.

if ($this->value) {
    if ($this->value === 'abc') {
         $x = $this->x();
    }

    $x = 'lababala';

    if ($this->value === '123') {
         $x = $this->y();
    }

    $end = new object();
}
0

There are 0 answers