Skip to content

Commit

Permalink
this is 2.7.1
Browse files Browse the repository at this point in the history
  • Loading branch information
futtta committed May 8, 2020
1 parent 2ef6f78 commit 6fcb0f2
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 9 deletions.
4 changes: 2 additions & 2 deletions autoptimize.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: Autoptimize
* Plugin URI: https://autoptimize.com/
* Description: Makes your site faster by optimizing CSS, JS, Images, Google fonts and more.
* Version: 2.7.0
* Version: 2.7.1
* Author: Frank Goossens (futtta)
* Author URI: https://autoptimize.com/
* Text Domain: autoptimize
Expand All @@ -20,7 +20,7 @@
exit;
}

define( 'AUTOPTIMIZE_PLUGIN_VERSION', '2.7.0' );
define( 'AUTOPTIMIZE_PLUGIN_VERSION', '2.7.1' );

// plugin_dir_path() returns the trailing slash!
define( 'AUTOPTIMIZE_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
Expand Down
6 changes: 4 additions & 2 deletions classes/autoptimizeCriticalCSSBase.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,18 +136,20 @@ public static function fetch_options() {
}

public function on_upgrade() {
global $ao_ccss_key;

// Create the cache directory if it doesn't exist already.
if ( ! file_exists( AO_CCSS_DIR ) ) {
mkdir( AO_CCSS_DIR, 0755, true );
}

// Create a scheduled event for the queue.
if ( ! wp_next_scheduled( 'ao_ccss_queue' ) ) {
if ( isset( $ao_ccss_key ) && ! empty( $ao_ccss_key ) && ! wp_next_scheduled( 'ao_ccss_queue' ) ) {
wp_schedule_event( time(), apply_filters( 'ao_ccss_queue_schedule', 'ao_ccss' ), 'ao_ccss_queue' );
}

// Create a scheduled event for log maintenance.
if ( ! wp_next_scheduled( 'ao_ccss_maintenance' ) ) {
if ( isset( $ao_ccss_key ) && ! empty( $ao_ccss_key ) && ! wp_next_scheduled( 'ao_ccss_maintenance' ) ) {
wp_schedule_event( time(), 'twicedaily', 'ao_ccss_maintenance' );
}
}
Expand Down
2 changes: 1 addition & 1 deletion classes/autoptimizeCriticalCSSCron.php
Original file line number Diff line number Diff line change
Expand Up @@ -773,7 +773,7 @@ function ao_ccss_finclude( $finclude_raw ) {
}
}

public static function ao_ccss_cleaning() {
public function ao_ccss_cleaning() {
// Perform plugin maintenance
// Truncate log file >= 1MB .
if ( file_exists( AO_CCSS_LOG ) ) {
Expand Down
6 changes: 3 additions & 3 deletions classes/autoptimizeScripts.php
Original file line number Diff line number Diff line change
Expand Up @@ -208,13 +208,13 @@ public function read( $options )
// only optimize known good JS?
$whitelist_js = apply_filters( 'autoptimize_filter_js_whitelist', '', $this->content );
if ( ! empty( $whitelist_js ) ) {
$this->whitelist = array_filter( array_map( 'trim', explode( ', ', $whitelist_js ) ) );
$this->whitelist = array_filter( array_map( 'trim', explode( ',', $whitelist_js ) ) );
}

// is there JS we should simply remove?
$removable_js = apply_filters( 'autoptimize_filter_js_removables', '', $this->content );
if ( ! empty( $removable_js ) ) {
$this->jsremovables = array_filter( array_map( 'trim', explode( ', ', $removable_js ) ) );
$this->jsremovables = array_filter( array_map( 'trim', explode( ',', $removable_js ) ) );
}

// only header?
Expand Down Expand Up @@ -267,7 +267,7 @@ public function read( $options )
}
$excl_js_arr = array_keys( $exclude_js );
} else {
$excl_js_arr = array_filter( array_map( 'trim', explode( ', ', $exclude_js ) ) );
$excl_js_arr = array_filter( array_map( 'trim', explode( ',', $exclude_js ) ) );
}
$this->dontmove = array_merge( $excl_js_arr, $this->dontmove );
}
Expand Down
5 changes: 4 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Donate link: http://blog.futtta.be/2013/10/21/do-not-donate-to-me/
Requires at least: 4.9
Tested up to: 5.4
Requires PHP: 5.6
Stable tag: 2.7.0
Stable tag: 2.7.1

Autoptimize speeds up your website by optimizing JS, CSS, images (incl. lazy-load), HTML and Google Fonts, asyncing JS, removing emoji cruft and more.

Expand Down Expand Up @@ -295,6 +295,9 @@ Just [fork Autoptimize on Github](https://github.com/futtta/autoptimize) and cod

== Changelog ==

= 2.7.1 =
* A couple of small bugfixes, see the [GitHub commit log](https://github.com/futtta/autoptimize/commits/beta).

= 2.7.0 =
* Integration of critical CSS power-up.
* New option to ensure missing autoptimized files are served with fallback JS/ CSS.
Expand Down

0 comments on commit 6fcb0f2

Please sign in to comment.