| @@ -1,8 +1,15 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | namespace Elementor\Modules\AtomicWidgets\Styles; |
| 4 | 4 | |
| 5 | +use Elementor\Core\Base\Document; | |
| 6 | +use Elementor\Core\Breakpoints\Breakpoint; | |
| 7 | +use Elementor\Core\Utils\Collection; | |
| 8 | +use Elementor\Modules\AtomicWidgets\Memo; | |
| 9 | +use Elementor\Modules\AtomicWidgets\Cache_Validity; | |
| 10 | +use Elementor\Plugin; | |
| 11 | + | |
| 5 | 12 | if ( ! defined( 'ABSPATH' ) ) { |
| 6 | 13 | exit; // Exit if accessed directly. |
| 7 | 14 | } |
| 8 | 15 | |
| @@ -43,16 +50,9 @@ | ||
| 43 | 50 | } |
| 44 | 51 | |
| 45 | 52 | private function update_fonts( array $fonts ) { |
| 46 | 53 | $style_fonts_key = $this->get_key(); |
| 47 | - | |
| 48 | - if ( empty( $fonts ) ) { | |
| 49 | - delete_option( $style_fonts_key ); | |
| 50 | - | |
| 51 | - return; | |
| 52 | - } | |
| 53 | - | |
| 54 | - update_option( $style_fonts_key, $fonts, false ); | |
| 54 | + update_option( $style_fonts_key, $fonts ); | |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | private function get_key(): string { |
| 58 | 58 | return FONTS_KEY_PREFIX . $this->style_key; |