Skip to content
Snippets Groups Projects
Unverified Commit 23d7fdee authored by Daniel Kesselberg's avatar Daniel Kesselberg
Browse files

Skip check if CONSTANT on real object is used

parent f3457858
No related branches found
No related tags found
No related merge requests found
...@@ -162,7 +162,7 @@ class NodeVisitor extends NodeVisitorAbstract { ...@@ -162,7 +162,7 @@ class NodeVisitor extends NodeVisitorAbstract {
if ($node->class instanceof Name) { if ($node->class instanceof Name) {
$this->checkBlackList($node->class->toString(), CodeChecker::CLASS_CONST_FETCH_NOT_ALLOWED, $node); $this->checkBlackList($node->class->toString(), CodeChecker::CLASS_CONST_FETCH_NOT_ALLOWED, $node);
} }
if ($node->class instanceof Node\Expr\Variable) { if ($node->class instanceof Node\Expr\Variable || $node->class instanceof Node\Expr\PropertyFetch) {
/** /**
* TODO: find a way to detect something like this: * TODO: find a way to detect something like this:
* $c = "OC_API"; * $c = "OC_API";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment