Astra_Customizer::regenerate_astra_fonts_folder()
Reset font folder.
Description
Return
(void)
Source
File: inc/customizer/class-astra-customizer.php
public function regenerate_astra_fonts_folder() { check_ajax_referer( 'astra-regenerate-local-fonts', 'nonce' ); if ( ! current_user_can( 'edit_theme_options' ) ) { wp_send_json_error( 'invalid_permissions' ); } if ( astra_get_option( 'load-google-fonts-locally' ) ) { $local_font_loader = astra_webfont_loader_instance( '' ); $flushed = $local_font_loader->astra_delete_fonts_folder(); if ( ! $flushed ) { wp_send_json_error( 'failed_to_flush' ); } wp_send_json_success(); } wp_send_json_error( 'no_font_loader' ); }
Expand full source code Collapse full source code View on Trac
Changelog
Version | Description |
---|---|
3.6.0 | Introduced. |