Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DevelopmentCodeFragment does not work in Files with namespace #532

Closed
Stoffo opened this issue Nov 7, 2017 · 3 comments · Fixed by #571
Closed

DevelopmentCodeFragment does not work in Files with namespace #532

Stoffo opened this issue Nov 7, 2017 · 3 comments · Fixed by #571

Comments

@Stoffo
Copy link

Stoffo commented Nov 7, 2017

Hi,

the DevelopmentCodeFragment Rule does not detect unwanted functions like var_dump, print_r when they occur in a non-global namespace.

This works:

<?php

class Foo
{
    private function baz()
    {
        var_dump("");
    }
}

The method Foo::baz() calls the typical debug function var_dump() which is mostly only used during development.

This does not work:

<?php

namespace baz;

class Foo
{
    private function baz()
    {
        var_dump("");
    }
}
@mstaack
Copy link

mstaack commented Jan 11, 2018

any updates on this one?

@jframos0
Copy link

jframos0 commented Feb 8, 2018

it's still not working with namespace :(

@tariq86
Copy link
Contributor

tariq86 commented May 11, 2018

I just submitted PR #571 to address this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

5 participants