Don't set up queue if write key is not set #1
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.
Hi,
You've done a nice job cleaning up this fork for PHP 8, but it sounds like Graham isn't too bothered about merging or maintaining it. I've already made this PR against his repo, but I figured it might do better bundled in with your changes, so i thought I'd post it here too.
It simply moves the initial queue setup inside the key check, which means that the queue cleanup functions don't get called on shutdown if you have no key. If you don't do this, and you don't have a key set, it will throw an error at the end of every request. If you don't have a key set, it then just fails quietly – which is very useful for dev or staging envs – in my case this issue was causing 32,000 exceptions/day on my staging server before I figured it out!