Modernised code base and fixed PHP deprecations#116
Draft
NickSdot wants to merge 67 commits into
Draft
Conversation
Note: the class has clearly bugs with undefined variables and stuff, but it is too risky without tests to get this actually done.
Note: the class has clearly bugs with undefined variables and stuff, but it is too risky without tests to get this actually done.
These commands seem generally broken or depend on specific users local machines -- not worth to touch.
Contributor
Author
|
Re: #114 (comment) If you want me to remove the commit message prefixes here I can do that. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Don't freak out about the size of the PR -- it's mostly mechanical changes. 😅
Yesterday when I was sending the PECL deprecation PRs I had struggle to get the site locally running because of still PHP 7.2 being used. Event though PECL is deprecated it likely will be online in maintenance mode at least a few more years. I thought it would be a bad idea to have it stuck on PHP 7.2 forever, so I thought why not give it a shot...
This PR makes PECL web run on PHP 8.3.
Additionally, while I was working on it I made (mostly) type related, mechanical IDE-proposed changes -- as well as some light cleanups and usage of more modern features (removed dead code, used
??operator where sensible, used constructor property promotion, etc.). My goal was to get at least a bit of type coverage to increase confidence when making changes, make things more readable/neat where possible, and get IDE inspection reporting per file the best it can get.All changes I made were conservative, where I wasn't sure if safe I used PHPDoc types instead of native types.
I want to highlight the change of
Auth::secure(). The IDE marked the$admin` argument as unused (func_get_arg usage), which I found unfortunate in auth related code. I checked all call sites, and I do not see a reason why the old code was as it was -- hence I refactored it. I'd appreciate an extra careful look at that.Marked the PR as draft because I am:
So this PR is not really more than a starting point, and I wanted to feel out if this even has chances to get merged.
Please let me know if this is something you would be interested in, and if you have some guidance what could be next, I'd appreciate it. Thank you!