Skip to content

Commit d810274

Browse files
committed
Release version 2.6.1
* This maintenance release has a security vulnerability patch, please run this update. * Security – This release has a patch for a security vulnerability identified by Wordfence scan
1 parent 8e7faf9 commit d810274

File tree

5 files changed

+31
-7
lines changed

5 files changed

+31
-7
lines changed

a3-lazy-load.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
Plugin Name: a3 Lazy Load
44
Description: Speed up your site and enhance frontend user's visual experience in PC's, Tablets and mobile with a3 Lazy Load.
5-
Version: 2.6.0
5+
Version: 2.6.1
66
Author: a3rev Software
77
Author URI: https://a3rev.com/
88
Requires at least: 5.6
@@ -31,7 +31,7 @@
3131

3232
define( 'A3_LAZY_LOAD_KEY', 'a3_lazy_load' );
3333
define( 'A3_LAZY_LOAD_PREFIX', 'a3_lazy_load_' );
34-
define( 'A3_LAZY_VERSION', '2.6.0' );
34+
define( 'A3_LAZY_VERSION', '2.6.1' );
3535
define( 'A3_LAZY_LOAD_G_FONTS', false );
3636

3737
use \A3Rev\LazyLoad\FrameWork;

admin/admin-interface.php

+17
Original file line numberDiff line numberDiff line change
@@ -618,6 +618,10 @@ public function save_settings( $options, $option_name = '' ) {
618618
foreach ( $options as $value ) {
619619
if ( ! isset( $value['type'] ) ) continue;
620620
if ( in_array( $value['type'], array( 'row', 'column', 'heading', 'ajax_submit', 'ajax_multi_submit' ) ) ) continue;
621+
if ( stristr( $value['type'], 'custom_' ) !== false ) {
622+
do_action( $this->plugin_name . '_save_setting_' . $value['type'], $value );
623+
continue;
624+
}
621625

622626
// Save for global settings of plugin framework
623627
switch ( $value['type'] ) {
@@ -1030,6 +1034,14 @@ public function save_settings( $options, $option_name = '' ) {
10301034
/*-----------------------------------------------------------------------------------*/
10311035

10321036
public function reset_settings( $options, $option_name = '', $reset = false, $free_version = false ) {
1037+
1038+
if ( $reset ) {
1039+
check_admin_referer( 'save_settings_' . $this->plugin_name );
1040+
1041+
if ( ! current_user_can( 'manage_options' ) ) {
1042+
return false;
1043+
}
1044+
}
10331045

10341046
if ( !is_array( $options ) || count( $options ) < 1 ) return;
10351047

@@ -1089,6 +1101,11 @@ public function reset_settings( $options, $option_name = '', $reset = false, $fr
10891101
if ( ! isset( $value['id'] ) || trim( $value['id'] ) == '' ) continue;
10901102
if ( ! isset( $value['default'] ) ) $value['default'] = '';
10911103
if ( ! isset( $value['free_version'] ) ) $value['free_version'] = false;
1104+
1105+
if ( stristr( $value['type'], 'custom_' ) !== false ) {
1106+
do_action( $this->plugin_name . '_reset_setting_' . $value['type'], $value );
1107+
continue;
1108+
}
10921109

10931110
// For way it has an option name
10941111
if ( ! isset( $value['separate_option'] ) ) $value['separate_option'] = false;

admin/admin-ui.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class Admin_UI
3333
* You must change to correct plugin name that you are working
3434
*/
3535

36-
public $framework_version = '2.6.0';
36+
public $framework_version = '2.6.2';
3737
public $plugin_name = A3_LAZY_LOAD_KEY;
3838
public $plugin_path = A3_LAZY_LOAD_NAME;
3939
public $google_api_key_option = '';
@@ -353,7 +353,7 @@ public function plugin_extension_start( $echo = true ) {
353353
$output = apply_filters( $this->plugin_name . '_plugin_extension_start', $output );
354354

355355
if ( $echo )
356-
echo $output;
356+
echo wp_kses_post( $output );
357357
else
358358
return $output;
359359
}

admin/includes/fonts_face.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -623,9 +623,9 @@ public function generate_font_css( $option, $em = '1.2' ) {
623623
$font_css = '';
624624

625625
if ( !@$option['style'] && !@$option['size'] && !@$option['color'] )
626-
$font_css = 'font-family: '.stripslashes($option["face"]).' !important;';
626+
$font_css = 'font-family: '.stripslashes( str_replace( array( '"', "'" ), '', $option["face"] ) ).' !important;';
627627
else
628-
$font_css = 'font:'.$option['style'].' '.$option['size'].'/' . $line_height . ' ' .stripslashes($option['face']).' !important; color:'.$option['color'].' !important;';
628+
$font_css = 'font:'.$option['style'].' '.$option['size'].'/' . $line_height . ' ' .stripslashes( str_replace( array( '"', "'" ), '', $option['face'] ) ).' !important; color:'.$option['color'].' !important;';
629629

630630
return apply_filters( $this->plugin_name . '_generate_font_css', $font_css, $option, $em );
631631
}

readme.txt

+8-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Contributors: a3rev, a3rev Software, nguyencongtuan
33
Tags: a3 lazy load, Lazy Loading, image lazy load, lazyload
44
Requires at least: 5.6
55
Tested up to: 6.0
6-
Stable tag: 2.6.0
6+
Stable tag: 2.6.1
77
License: GPLv3
88
License URI: http://www.gnu.org/licenses/gpl-3.0.html
99

@@ -202,6 +202,10 @@ Filter tags to add to class name of theme to exclude lazy load on images or vide
202202

203203
== Changelog ==
204204

205+
= 2.6.1 - 2022/10/04 =
206+
* This maintenance release has a security vulnerability patch, please run this update.
207+
* Security – This release has a patch for a security vulnerability identified by Wordfence scan
208+
205209
= 2.6.0 - 2022/07/20 =
206210
* This release adds the option to switch OFF WordPress Core Lazy Load.
207211
* Feature - Add Option to completely disable WordPress Core Lazy Load.
@@ -614,6 +618,9 @@ Filter tags to add to class name of theme to exclude lazy load on images or vide
614618

615619
== Upgrade Notice ==
616620

621+
= 2.6.1 =
622+
This maintenance release has a security vulnerability patch, please run this update.
623+
617624
= 2.6.0 =
618625
This release adds the option to switch OFF WordPress Core Lazy Load.
619626

0 commit comments

Comments
 (0)