Skip to content

The "Squiz.WhiteSpace.MemberVarSpacing" not respecting "var" #410

@aik099

Description

@aik099

When class property is defined via var and not public/protected/private keywords, then it's reported as error and auto-fixer added empty line before property declaration.

<?php

class ProductHelper extends kHelper
{

    /**
     * Specification fields
     *
     * @var Array
     */
    var $specificationFields = array();

}

Error: Expected 1 blank line before member var; 0 found (Squiz.WhiteSpace.MemberVarSpacing.Incorrect)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions