Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor core resource URL filtering and multisite handling #157

Merged
merged 6 commits into from
Aug 13, 2024

Conversation

jazzsequence
Copy link
Contributor

@jazzsequence jazzsequence commented Aug 12, 2024

Fixes #156

This pull request refactors the fix_core_resource_urls function to move the multisite handling into the function. It introduces a new function filter_core_resource_urls to run the fix_core_resource_urls filter on init. This replaces the previous version that wrapped a $filters variable in the global scope inside the multisite check.

It also simplifies the logic in adjust_main_site_urls

@jazzsequence jazzsequence requested review from a team as code owners August 12, 2024 18:01
@jazzsequence
Copy link
Contributor Author

single site test (despite the site name): https://dev-wpcm-subdirectory-test.pantheonsite.io/

multisite tests coming

@jazzsequence
Copy link
Contributor Author

@jazzsequence jazzsequence self-assigned this Aug 12, 2024
@jazzsequence jazzsequence merged commit 9db62d5 into default Aug 13, 2024
11 checks passed
@jazzsequence jazzsequence deleted the 156-fix-core-resources-on-single-sites branch August 13, 2024 20:13
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.

WordPress Core resources still create 404 errors on single sites
2 participants