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

Strange: Case mismatch on class name error with even stranger fix. #97

Closed
josefsabl opened this issue Feb 24, 2016 · 3 comments
Closed

Strange: Case mismatch on class name error with even stranger fix. #97

josefsabl opened this issue Feb 24, 2016 · 3 comments

Comments

@josefsabl
Copy link

@josefsabl josefsabl commented Feb 24, 2016

Today I updated are composer dependencies and our app started to throw this exception:

https://dl.dropboxusercontent.com/u/3215457/exception--2016-02-24--13-59--3ca7ce7b19.html

The solution to fix it was to change the routerFactory like this:

http://screenpresso.com/=qHr2c

@milo

This comment has been minimized.

Copy link
Member

@milo milo commented Feb 24, 2016

Imho, you should not use leading \ in use clause.

EDIT: But agree that message is strange :)

@dg dg closed this in 604ec5a Feb 24, 2016
dg added a commit that referenced this issue Feb 24, 2016
@josefsabl

This comment has been minimized.

Copy link
Author

@josefsabl josefsabl commented Feb 24, 2016

I never realized that use usually doesn't use the leading slash. Probably because Netbeans automatically puts it in there automatically. Anyways, thanks for the fix.

@lookyman

This comment has been minimized.

Copy link
Contributor

@lookyman lookyman commented Feb 24, 2016

Actually, according to PHP documentation,

the leading backslash is unnecessary and not recommended, as import names must be fully qualified, and are not processed relative to the current namespace

https://secure.php.net/manual/en/language.namespaces.importing.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.