Skip to content

False positive for "LogicalOperators" rule #81

@aik099

Description

@aik099

The common way of dealing with accessing PHP files directly from web browser (when codebase is located within DocumentRoot, like in WordPress) is placing following code on top of PHP file:

defined('FULL_PATH') or die('restricted access!');

Name of the constant is different for each framework, but construct stays the same (more or less).

I think, that this should be added as exclusion to LogicalOperators rule, because right now I'm getting following error in every PHP file:

1) core/units/related_searches/related_searches_config.php on line 15
Avoid using AND, OR and XOR (in favor of || and &&) as they may cause subtle precedence bugs
> defined('FULL_PATH') or die('restricted access!');
For more information execute 'psecio-parse rules LogicalOperators'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions