OMGF | GDPR/DSVGO Compliant, Faster Google Fonts. Easy. - Version 3.0.1

Version Description

  • [BUGFIX] Passing glue string after array is deprecated. Swap the parameters.
Download this release

Release Info

Developer DaanvandenBergh
Plugin Icon 128x128 OMGF | GDPR/DSVGO Compliant, Faster Google Fonts. Easy.
Version 3.0.1
Comparing to
See all releases

Code changes from version 3.0.0 to 3.0.1

host-webfonts-local.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: OMGF
5
  * Plugin URI: https://daan.dev/wordpress-plugins/host-google-fonts-locally
6
  * Description: Minimize DNS requests and leverage browser cache by easily saving Google Fonts to your server and removing the external Google Fonts.
7
- * Version: 3.0.0
8
  * Author: Daan van den Bergh
9
  * Author URI: https://daan.dev
10
  * License: GPL2v2 or later
@@ -57,7 +57,7 @@ function omgf_autoload($class)
57
 
58
  $pieces = preg_split('/(?=[A-Z])/', lcfirst($path[$i]));
59
 
60
- $filename .= 'class-' . strtolower(implode($pieces, '-')) . '.php';
61
  }
62
 
63
  return include OMGF_PLUGIN_DIR . 'includes/' . $filename;
4
  * Plugin Name: OMGF
5
  * Plugin URI: https://daan.dev/wordpress-plugins/host-google-fonts-locally
6
  * Description: Minimize DNS requests and leverage browser cache by easily saving Google Fonts to your server and removing the external Google Fonts.
7
+ * Version: 3.0.1
8
  * Author: Daan van den Bergh
9
  * Author URI: https://daan.dev
10
  * License: GPL2v2 or later
57
 
58
  $pieces = preg_split('/(?=[A-Z])/', lcfirst($path[$i]));
59
 
60
+ $filename .= 'class-' . strtolower(implode('-', $pieces)) . '.php';
61
  }
62
 
63
  return include OMGF_PLUGIN_DIR . 'includes/' . $filename;
includes/class-ajax.php CHANGED
@@ -114,7 +114,7 @@ class OMGF_AJAX
114
 
115
  // Retrieve available font styles.
116
  foreach ($search_google_fonts as $font) {
117
- $selected_subsets = implode($font['selected_subsets'], ',');
118
  $api = new OMGF_API();
119
  $fonts[] = $api->get_font_styles($font['subset_font'], $selected_subsets);
120
  }
114
 
115
  // Retrieve available font styles.
116
  foreach ($search_google_fonts as $font) {
117
+ $selected_subsets = implode(',', $font['selected_subsets']);
118
  $api = new OMGF_API();
119
  $fonts[] = $api->get_font_styles($font['subset_font'], $selected_subsets);
120
  }
includes/class-api.php CHANGED
@@ -58,7 +58,7 @@ class OMGF_API
58
  'font_family' => $variant->fontFamily,
59
  'font_weight' => $variant->fontWeight,
60
  'font_style' => $variant->fontStyle,
61
- 'local' => implode($variant->local, ','),
62
  'preload' => 0,
63
  'downloaded' => 0,
64
  'url_ttf' => $variant->ttf,
58
  'font_family' => $variant->fontFamily,
59
  'font_weight' => $variant->fontWeight,
60
  'font_style' => $variant->fontStyle,
61
+ 'local' => implode(',', $variant->local),
62
  'preload' => 0,
63
  'downloaded' => 0,
64
  'url_ttf' => $variant->ttf,
includes/class-setup.php CHANGED
@@ -48,7 +48,11 @@ class OMGF_Setup
48
  */
49
  public function run_db_updates()
50
  {
51
- $this->migrate_db();
 
 
 
 
52
 
53
  $this->drop_tables();
54
  }
48
  */
49
  public function run_db_updates()
50
  {
51
+ $table_exists = $this->wpdb->query("SHOW TABLES LIKE '" . OMGF_DB_TABLENAME . "'");
52
+
53
+ if ($table_exists) {
54
+ $this->migrate_db();
55
+ }
56
 
57
  $this->drop_tables();
58
  }
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: DaanvandenBergh
3
  Tags: google, fonts, preload, font-display, webfonts, subsets, remove, minimize, external, requests, leverage, browser, cache
4
  Requires at least: 4.6
5
  Tested up to: 5.4
6
- Stable tag: 3.0.0
7
  Requires PHP: 7.0
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -105,6 +105,9 @@ N/A
105
 
106
  == Changelog ==
107
 
 
 
 
108
  = 3.0.0 =
109
  *OMGF - CORONA EDITION*
110
  * Moved Welcome-panel to the side.
3
  Tags: google, fonts, preload, font-display, webfonts, subsets, remove, minimize, external, requests, leverage, browser, cache
4
  Requires at least: 4.6
5
  Tested up to: 5.4
6
+ Stable tag: 3.0.1
7
  Requires PHP: 7.0
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
105
 
106
  == Changelog ==
107
 
108
+ = 3.0.1 =
109
+ * [BUGFIX] Passing glue string after array is deprecated. Swap the parameters.
110
+
111
  = 3.0.0 =
112
  *OMGF - CORONA EDITION*
113
  * Moved Welcome-panel to the side.