Skip to content

docs: clarify mutable and immutable URI query methods#10348

Merged
paulbalandan merged 1 commit into
codeigniter4:4.8from
memleakd:docs/uri-query-immutability
Jun 30, 2026
Merged

docs: clarify mutable and immutable URI query methods#10348
paulbalandan merged 1 commit into
codeigniter4:4.8from
memleakd:docs/uri-query-immutability

Conversation

@memleakd

Copy link
Copy Markdown
Contributor

Description

This follows up on #10268 and @michalsn’s suggestion to make the URI query docs clearer.

The URI user guide now lists the mutable query methods next to their immutable alternatives, and explicitly notes that the with*() helpers return cloned URI instances while the older methods mutate the current instance.

I also added non-runtime TODO notes to the mutable query method docblocks for the future major-version deprecation direction. These are not runtime deprecations and do not add @deprecated tags.

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value (without duplication)
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

- add a user guide table mapping mutable query methods to immutable helpers
- note that immutable query helpers clone the URI instead of mutating it
- add TODO notes for future mutable query method deprecations

Signed-off-by: memleakd <121398829+memleakd@users.noreply.github.com>
@github-actions github-actions Bot added the 4.8 PRs that target the `4.8` branch. label Jun 29, 2026
@michalsn michalsn added the documentation Pull requests for documentation only label Jun 29, 2026

@michalsn michalsn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the follow-up!

@paulbalandan paulbalandan merged commit b8c152d into codeigniter4:4.8 Jun 30, 2026
57 checks passed
@paulbalandan

Copy link
Copy Markdown
Member

Thank you, @memleakd

@memleakd memleakd deleted the docs/uri-query-immutability branch June 30, 2026 07:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4.8 PRs that target the `4.8` branch. documentation Pull requests for documentation only

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants