Astra_WebFont_Loader::schedule_cleanup()
Schedule a cleanup.
Description
Deletes the fonts files on a regular basis. This way font files will get updated regularly, and we avoid edge cases where unused files remain in the server.
Return
(void)
Source
File: inc/lib/webfont/class-astra-webfont-loader.php
public function schedule_cleanup() { if ( ! is_multisite() || ( is_multisite() && is_main_site() ) ) { if ( ! wp_next_scheduled( 'astra_delete_fonts_folder' ) && ! wp_installing() ) { wp_schedule_event( time(), self::CLEANUP_FREQUENCY, 'astra_delete_fonts_folder' ); // phpcs:ignore WPThemeReview.PluginTerritory.ForbiddenFunctions.cron_functionality_wp_schedule_event } } }
Expand full source code Collapse full source code View on Trac
Changelog
Version | Description |
---|---|
3.6.0 | Introduced. |