-
Notifications
You must be signed in to change notification settings - Fork 79
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
Debug 'get_font_stylesheet_url'
fatal
#1019
Comments
In addition to #1020, I added some temporary logging to the parent theme in |
I managed to reproduce the error, but only through a The backtrace is exactly as you see it through the logging.
|
Seems like it only happens when the subdomain is capitalised e.g. |
I was able to work around it (I think!) by adding the capitalised subdomain to the wp-config file, but unsure if that's the right thing to do here. |
Ah, yeah, that's a great find, thanks! I'm guessing most browsers normalize/lowercase the domain automatically, while curl doesn't. This seems like a good fix to me, what do you think? -switch ( $_SERVER['HTTP_HOST'] ) {
+switch ( strtolower( $_SERVER['HTTP_HOST'] ) ) { That way it doesn't matter which letters the client capitalizes. |
👍 Yeah, that makes sense and should cover this. |
Production fixed in |
There are sporadic
get_font_stylesheet_url()
fatals in the error log:Call to undefined function WordPressdotorg\MU_Plugins\Global_Fonts\get_font_stylesheet_url() in wp-content/themes/wporg-parent-2021/functions.php:46
I can't reproduce it, but it's been happening regularly since I added the parent theme in #1013 . It mostly appears to happen with pentesters, but I imagine it'll happen with others once the Events root site launches.
Because it's a fatal, we're not seeing the backtrace etc, but adding some extra logging may help.
The text was updated successfully, but these errors were encountered: