public static is_development_version ( ) |
public static function is_development_version()
{
/**
* Allows filtering whether this is a development version of Jetpack.
*
* This filter is especially useful for tests.
*
* @since 4.3.0
*
* @param bool $development_version Is this a develoment version of Jetpack?
*/
return (bool) apply_filters('jetpack_development_version', !preg_match('/^\\d+(\\.\\d+)+$/', Jetpack_Constants::get_constant('JETPACK__VERSION')));
}
function twentyfifteen_init_jetpack() { /** * Add our compat CSS file for custom widget stylings and such. * Set the version equal to filemtime for development builds, and the JETPACK__VERSION for production. */ $version = Jetpack::is_development_version() ? filemtime(plugin_dir_path(__FILE__) . 'twentyfifteen.css') : JETPACK__VERSION; wp_enqueue_style('twentyfifteen-jetpack', plugins_url('twentyfifteen.css', __FILE__), array(), $version); wp_style_add_data('twentyfifteen-jetpack', 'rtl', 'replace'); }