Replace jeremeamia/superclosure with opis/closure - #37238
Merged
Conversation
Codecov Report
@@ Coverage Diff @@
## master #37238 +/- ##
=========================================
Coverage 64.92% 64.92%
- Complexity 19148 19149 +1
=========================================
Files 1267 1267
Lines 74895 74896 +1
Branches 1331 1331
=========================================
+ Hits 48626 48627 +1
Misses 25877 25877
Partials 392 392
Continue to review full report at Codecov.
|
phil-davis
force-pushed
the
opis-closure
branch
from
April 13, 2020 06:50
6a7bf2f to
d7a55bd
Compare
VicDeo
suggested changes
Apr 13, 2020
| protected function run($serializedCallable) { | ||
| $serializer = new Serializer(); | ||
| $callable = $serializer->unserialize($serializedCallable); | ||
| $serializedClosure = \unserialize($serializedCallable); |
Contributor
There was a problem hiding this comment.
compare result with false to avoid getClosure() on false below?
Contributor
Author
There was a problem hiding this comment.
I used method_exists because it is also nice to know that the unserialized "thing" is an object that has the required method. I checked that if $serializedClosure is not even an object (e.g. is false or "abc" or...) then method_exists happily returns false.
phil-davis
force-pushed
the
opis-closure
branch
from
April 13, 2020 10:30
d7a55bd to
586693a
Compare
VicDeo
approved these changes
Apr 13, 2020
65 tasks
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.
Description
jeremeamia/superclosurelibrary is no longer maintained and is only officially tested up to PHP 7.2.https://github.com/jeremeamia/super_closure/blob/master/README.md
Replace it with the recommended https://github.com/opis/closure library.
This happens to also get rid of some
symfony/polyfilldependencies.And means we are using a dependency that is officially tested on PHP 7.3 and 7.4
How Has This Been Tested?
CI and local run of unit tests:
Types of changes
Checklist: