-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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 #928 : make compatible to extends #936
Conversation
@pquerner btw why are you using the |
I can't. Not yet anyways. |
I think this broke Agent: jenssegers/agent#208 Everyone using Agent is forced to revert/pin to 2.8.41 to maintain |
What is your suggested way of a fix? Sorry I didnt catch the BC with the getter. |
The problem is IMO this should be reverted and continue using the static properties. This was a breaking API change and shouldn't have been done in a patch release (though |
I dont see that as a working solution. Maybe for your 3rd party library, but not in favor of extendability. Can you guide me what agent did by overwriting this |
See jenssegers/agent#208 for the explanation. |
Yes, again: Agent has overwritten an unused method to extend some functionality in 3rd party code and now the getter is actually used in here its causing issues. Move that custom code (merging / removing of other UAs) to somewhere else. Maybe we can find a way of altering the rules to-be-applied to some generic place? |
The problem is that lots of people use Agent (most of the Laravel community, and some others) and Agent is no longer maintained. So making breaking updates to Mobile-Detect means it breaks it "forever" for those users, unless they fork and fix it for themselves. Or we wait for a "blessed" fork, but that's asking a lot. I agree that the better solution would be a clean API, but the problem is lack of maintenance of Agent, and no alternatives for those users because it adds additional functionality that is must-have for a lot of people. I suggested Mobile-Detect ports the functionality from Agent in #940 and that would give a good migration path for everyone using Agent, and removing a link in the dependency chain. |
@francislavoie Okay, I'm reading this in details tonight, meanwhile: shot term: will revert this wdyt? |
Sounds great 🫶 |
Why is the version not pinned at "Agent"? Even more crucial when its abandoned. Sounds very silly to me all this. ^^ Just hope someone has time to work on mobile-detect to bring all those features. Even to the very old 2.x branch. |
Fixed, details at jenssegers/agent#207 (comment) |
Thanks, confirmed that |
Fixes #928