Repository navigation
Conversation
The offset of the definition in the targets list was used to unset an element of the service tuple itself, so removing one target dropped the whole targets list (or the URL list) of that service. Remove the target from the targets list and drop the service once it has none.
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.
AbstractRdapService::remove()looked up the definition in the service's targets list ($service[0]), but then used that offset to unset an element of the service tuple itself ($this->services[$key][$offset]). Removing one target therefore dropped the whole targets list (offset 0) or the URL list (offset 1) of that service:Now the target is removed from the targets list, the service entry is dropped once it has no targets left, and the services list is re-indexed.
phpcs and phpstan pass.