Skip to content

Commit

Permalink
v6.5.4: Fixed Google Fonts broken with the Async option. (HivePress #787
Browse files Browse the repository at this point in the history
)
  • Loading branch information
Hai Zheng committed Dec 13, 2024
1 parent 071e3d0 commit 052c3d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/optimize.cls.php
Original file line number Diff line number Diff line change
Expand Up @@ -601,11 +601,11 @@ private function _async_ggfonts()
$subset = empty($qs['subset']) ? '' : ':' . $qs['subset'];

foreach (array_filter(explode('|', $qs['family'])) as $v2) {
$families[] = $v2 . $subset;
$families[] = Str::trim_quotes($v2 . $subset);
}
}

$script .= '"' . Str::trim_quotes(implode('","', $families)) . ($this->_conf_css_font_display ? '&display=swap' : '') . '"';
$script .= '"' . implode('","', $families) . ($this->_conf_css_font_display ? '&display=swap' : '') . '"';

$script .= ']}};';

Expand Down

0 comments on commit 052c3d7

Please sign in to comment.