WIP
This commit is contained in:
@@ -40,6 +40,8 @@ class Site
|
||||
|
||||
private function bootstrap()
|
||||
{
|
||||
$this->checkfavicons();
|
||||
|
||||
// wordpress added this style for us, but we don't want it
|
||||
add_action('wp_enqueue_scripts', function () {
|
||||
wp_dequeue_style('classic-theme-styles');
|
||||
@@ -1301,4 +1303,17 @@ class Site
|
||||
|
||||
Util::processFieldGroup($templateFields);
|
||||
}
|
||||
|
||||
private function checkfavicons()
|
||||
{
|
||||
if (!is_dir($manifestFile = get_template_directory() . "/assets")) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (file_exists(get_template_directory() . "/assets/favicon.ico")) {
|
||||
add_action('wp_head', function () {
|
||||
echo "<link rel='icon' type='image/x-icon' href='".get_template_directory_uri()."/assets/favicon.ico'>";
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user