AMP for WP – Accelerated Mobile Pages - Version 1.0.58.3

Version Description

(9th July 2020) = * Fixed: Class 'AMPforWP\AMPVendor\WP_Error' not found error in the latest update of Jetpack #4624

Download this release

Release Info

Developer mohammed_kaludi
Plugin Icon 128x128 AMP for WP – Accelerated Mobile Pages
Version 1.0.58.3
Comparing to
See all releases

Code changes from version 1.0.58.2 to 1.0.58.3

README.md CHANGED
@@ -4,7 +4,7 @@ Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, go
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.4.2
7
- Stable tag: 1.0.58.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -193,6 +193,9 @@ Device testing done through [BrowserStack](https://www.browserstack.com)
193
 
194
  == Changelog ==
195
 
 
 
 
196
  = 1.0.58.2 (9th July 2020) =
197
  * Fixed: Category pages are not working properly #4579
198
 
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.4.2
7
+ Stable tag: 1.0.58.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
193
 
194
  == Changelog ==
195
 
196
+ = 1.0.58.3 (9th July 2020) =
197
+ * Fixed: Class 'AMPforWP\AMPVendor\WP_Error' not found error in the latest update of Jetpack #4624
198
+
199
  = 1.0.58.2 (9th July 2020) =
200
  * Fixed: Category pages are not working properly #4579
201
 
accelerated-moblie-pages.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Accelerated Mobile Pages
4
  Plugin URI: https://wordpress.org/plugins/accelerated-mobile-pages/
5
  Description: AMP for WP - Accelerated Mobile Pages for WordPress
6
- Version: 1.0.58.2
7
  Author: Ahmed Kaludi, Mohammed Kaludi
8
  Author URI: https://ampforwp.com/
9
  Donate link: https://www.paypal.me/Kaludi/25
@@ -20,7 +20,7 @@ define('AMPFORWP_PLUGIN_DIR_URI', plugin_dir_url(__FILE__));
20
  define('AMPFORWP_DISQUS_URL',plugin_dir_url(__FILE__).'includes/disqus.html');
21
  define('AMPFORWP_IMAGE_DIR',plugin_dir_url(__FILE__).'images');
22
  define('AMPFORWP_MAIN_PLUGIN_DIR', plugin_dir_path( __DIR__ ) );
23
- define('AMPFORWP_VERSION','1.0.58.2');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
3
  Plugin Name: Accelerated Mobile Pages
4
  Plugin URI: https://wordpress.org/plugins/accelerated-mobile-pages/
5
  Description: AMP for WP - Accelerated Mobile Pages for WordPress
6
+ Version: 1.0.58.3
7
  Author: Ahmed Kaludi, Mohammed Kaludi
8
  Author URI: https://ampforwp.com/
9
  Donate link: https://www.paypal.me/Kaludi/25
20
  define('AMPFORWP_DISQUS_URL',plugin_dir_url(__FILE__).'includes/disqus.html');
21
  define('AMPFORWP_IMAGE_DIR',plugin_dir_url(__FILE__).'images');
22
  define('AMPFORWP_MAIN_PLUGIN_DIR', plugin_dir_path( __DIR__ ) );
23
+ define('AMPFORWP_VERSION','1.0.58.3');
24
  define('AMPFORWP_EXTENSION_DIR',plugin_dir_path(__FILE__).'includes/options/extensions');
25
  if(!defined('AMPFROWP_HOST_NAME')){
26
  $urlinfo = get_bloginfo('url');
changelog.txt CHANGED
@@ -1,5 +1,8 @@
1
  == Changelog ==
2
 
 
 
 
3
  = 1.0.58.2 (9th July 2020) =
4
  * Fixed: Category pages are not working properly #4579
5
 
1
  == Changelog ==
2
 
3
+ = 1.0.58.3 (9th July 2020) =
4
+ * Fixed: Class 'AMPforWP\AMPVendor\WP_Error' not found error in the latest update of Jetpack #4624
5
+
6
  = 1.0.58.2 (9th July 2020) =
7
  * Fixed: Category pages are not working properly #4579
8
 
includes/vendor/amp/includes/sanitizers/class-amp-tree-style-sanitizer.php CHANGED
@@ -574,13 +574,13 @@ class AMP_treeshaking_Style_Sanitizer extends AMP_tree_Base_Sanitizer {
574
  $pattern = sprintf( '/\.(%s)$/i', implode( '|', $allowed_extensions ) );
575
  if ( ! preg_match( $pattern, $url ) ) {
576
  /* translators: %s: the file URL. */
577
- return new WP_Error( 'disallowed_file_extension', sprintf( __( 'File does not have an allowed file extension for filesystem access (%s).', 'amp' ), $url ) );
578
  }
579
  }
580
 
581
  if ( ! in_array( $url_host, $allowed_hosts, true ) ) {
582
  /* translators: %s: the file URL */
583
- return new WP_Error( 'external_file_url', sprintf( __( 'URL is located on an external domain: %s.', 'amp' ), $url_host ) );
584
  }
585
 
586
  $base_path = null;
@@ -603,11 +603,11 @@ class AMP_treeshaking_Style_Sanitizer extends AMP_tree_Base_Sanitizer {
603
 
604
  if ( ! $file_path || false !== strpos( $file_path, '../' ) || false !== strpos( $file_path, '..\\' ) ) {
605
  /* translators: %s: the file URL. */
606
- return new WP_Error( 'file_path_not_allowed', sprintf( __( 'Disallowed URL filesystem path for %s.', 'amp' ), $url ) );
607
  }
608
  if ( ! file_exists( $base_path . $file_path ) ) {
609
  /* translators: %s: the file URL. */
610
- return new WP_Error( 'file_path_not_found', sprintf( __( 'Unable to locate filesystem path for %s.', 'amp' ), $url ) );
611
  }
612
 
613
  return $base_path . $file_path;
574
  $pattern = sprintf( '/\.(%s)$/i', implode( '|', $allowed_extensions ) );
575
  if ( ! preg_match( $pattern, $url ) ) {
576
  /* translators: %s: the file URL. */
577
+ return new \WP_Error( 'disallowed_file_extension', sprintf( __( 'File does not have an allowed file extension for filesystem access (%s).', 'amp' ), $url ) );
578
  }
579
  }
580
 
581
  if ( ! in_array( $url_host, $allowed_hosts, true ) ) {
582
  /* translators: %s: the file URL */
583
+ return new \WP_Error( 'external_file_url', sprintf( __( 'URL is located on an external domain: %s.', 'amp' ), $url_host ) );
584
  }
585
 
586
  $base_path = null;
603
 
604
  if ( ! $file_path || false !== strpos( $file_path, '../' ) || false !== strpos( $file_path, '..\\' ) ) {
605
  /* translators: %s: the file URL. */
606
+ return new \WP_Error( 'file_path_not_allowed', sprintf( __( 'Disallowed URL filesystem path for %s.', 'amp' ), $url ) );
607
  }
608
  if ( ! file_exists( $base_path . $file_path ) ) {
609
  /* translators: %s: the file URL. */
610
+ return new \WP_Error( 'file_path_not_found', sprintf( __( 'Unable to locate filesystem path for %s.', 'amp' ), $url ) );
611
  }
612
 
613
  return $base_path . $file_path;
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: AMP, accelerated mobile pages, mobile, amp project, google amp, amp wp, go
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.4.2
7
- Stable tag: 1.0.58.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -190,6 +190,9 @@ You can contact us from [here](https://ampforwp.com/contact/)
190
 
191
  == Changelog ==
192
 
 
 
 
193
  = 1.0.58.2 (9th July 2020) =
194
  * Fixed: Category pages are not working properly #4579
195
 
4
  Donate link: https://www.paypal.me/Kaludi/25
5
  Requires at least: 3.0
6
  Tested up to: 5.4.2
7
+ Stable tag: 1.0.58.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
190
 
191
  == Changelog ==
192
 
193
+ = 1.0.58.3 (9th July 2020) =
194
+ * Fixed: Class 'AMPforWP\AMPVendor\WP_Error' not found error in the latest update of Jetpack #4624
195
+
196
  = 1.0.58.2 (9th July 2020) =
197
  * Fixed: Category pages are not working properly #4579
198