Skip to content

Conversation

mattmacneil
Copy link

Got rid of rtrim() deprecation that was logged for each page load in my local dev environment.

The issue was that trailingslashit() was sometimes getting a null value from parse_url(), which throwa a warning in php 8.1.

Updated line uses ?? operator so it always passes a string instead of null.

@mattmacneil mattmacneil requested review from a team as code owners August 7, 2025 21:23
@mattmacneil
Copy link
Author

mattmacneil commented Aug 8, 2025

Hmm I opened this PR thinking this was an issue "out of the box" with the Composer managed WP template; now I'm thinking this is might be something specific to my theme (which I assumed was the case at first but later dismissed in error).

Leaving this open in case it's still useful, but my assumption that everyone else using php 8.3 would constantly see this warning too is probably not correct.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant