-
Notifications
You must be signed in to change notification settings - Fork 15
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
FIX Linkfield sorting issue #262
FIX Linkfield sorting issue #262
Conversation
008ca5d
to
afd0c7e
Compare
afd0c7e
to
8e8a47a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works well locally.
$this->Sort = self::get()->filter([ | ||
$this->Sort = Link::get()->filter([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you may have found a bug in PHP itself! self
always refers to the class where the code is declared, so these should be identical. But for some reason the late static binding inside the get()
call is still bound to the specific subclass.
We should probably avoid calling static methods in general if this sort of thing is going to happen.
Nice find.
…ix-sorting FIX Linkfield sorting issue
…ix-sorting FIX Linkfield sorting issue
Description
The
self::get()
method returns list of specific Link types, because of this for each link type we reset and begin to increaseSort
again.Parent issue