Skip to content

Commit 90ccb58

Browse files
authored
Merge pull request #25 from brainstormforce/remove_font_google_list
console issue
2 parents 8156803 + 2b75612 commit 90ccb58

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

classes/class-custom-typekit-fonts-render.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,10 @@ function remove_typekit_font_google_url( $fonts ) {
247247
$kit_list = get_option( 'custom-typekit-fonts', array() );
248248
if ( ! empty( $kit_list['custom-typekit-font-details'] ) ) {
249249
foreach ( $kit_list['custom-typekit-font-details'] as $key => $value ) {
250+
$font_key = "'" . $value['family'] . "'" . ',' . $value['fallback'];
251+
if ( array_key_exists( $font_key, $fonts ) ) {
252+
unset( $fonts[ $font_key ] );
253+
}
250254
if ( array_key_exists( $key, $fonts ) ) {
251255
unset( $fonts[ $key ] );
252256
}

0 commit comments

Comments
 (0)