-
Notifications
You must be signed in to change notification settings - Fork 217
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
Prevent loading the Logger classes if WP_ROCKET_DEBUG is not enabled #5923
Comments
Acceptance Criteria:
|
Scope a solution ✅Load classes conditionally in https://github.com/wp-media/wp-rocket/blob/9822ca221e2070d39ecd1a8e74fec20b4351f3d5/views/cache/advanced-cache.php: wp-rocket/views/cache/advanced-cache.php Lines 31 to 58 in 9822ca2
}
Estimate the effort ✅[XS] |
|
@Tabrisrp Many Thanks 🙏 |
Following the post-mortem, we agreed to:
|
This is not something that can be implemented in the nearest future. |
Before submitting an issue please check that you’ve completed the following steps:
3.13.2
Describe the bug
Multiple
Logger
classes are loaded on theadvanced-cache.php
file.wp-rocket/views/cache/advanced-cache.php
Lines 33 to 52 in 9822ca2
Since logging WP Rocket only happens when the
WP_ROCKET_DEBUG
, we should make loading all related classes conditional to that.The impact on performance won't be significant, but it's still not
To Reproduce
N/A
Expected behavior
WP Rocket shouldn't load code/libraries not being used.
Screenshots
N/A
Additional context
Slack - https://wp-media.slack.com/archives/C43T1AYMQ/p1684220879897639?thread_ts=1684217755.309949&cid=C43T1AYMQ
Backlog Grooming (for WP Media dev team use only)
The text was updated successfully, but these errors were encountered: