Photo Gallery by Envira – Responsive Image Gallery for WordPress - Version 1.3.5.4

Version Description

  • Fix: Gallery slug would not save when changed
Download this release

Release Info

Developer n7studios
Plugin Icon 128x128 Photo Gallery by Envira – Responsive Image Gallery for WordPress
Version 1.3.5.4
Comparing to
See all releases

Code changes from version 1.3.5.3 to 1.3.5.4

envira-gallery-lite.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: Envira Gallery is best responsive WordPress gallery plugin. This is the lite version.
6
  * Author: Thomas Griffin
7
  * Author URI: http://thomasgriffinmedia.com
8
- * Version: 1.3.5.3
9
  * Text Domain: envira-gallery-lite
10
  *
11
  * Envira Gallery is free software: you can redistribute it and/or modify
@@ -53,7 +53,7 @@ class Envira_Gallery_Lite {
53
  *
54
  * @var string
55
  */
56
- public $version = '1.3.5.3';
57
 
58
  /**
59
  * Unique plugin slug identifier.
5
  * Description: Envira Gallery is best responsive WordPress gallery plugin. This is the lite version.
6
  * Author: Thomas Griffin
7
  * Author URI: http://thomasgriffinmedia.com
8
+ * Version: 1.3.5.4
9
  * Text Domain: envira-gallery-lite
10
  *
11
  * Envira Gallery is free software: you can redistribute it and/or modify
53
  *
54
  * @var string
55
  */
56
+ public $version = '1.3.5.4';
57
 
58
  /**
59
  * Unique plugin slug identifier.
includes/admin/metaboxes.php CHANGED
@@ -812,8 +812,12 @@ class Envira_Gallery_Metaboxes_Lite {
812
 
813
  // If on an envira post type, map the title and slug of the post object to the custom fields if no value exists yet.
814
  if ( isset( $post->post_type ) && 'envira' == $post->post_type ) {
815
- $settings['config']['title'] = trim( strip_tags( $post->post_title ) );
816
- $settings['config']['slug'] = sanitize_text_field( $post->post_name );
 
 
 
 
817
  }
818
 
819
  // Provide a filter to override settings.
812
 
813
  // If on an envira post type, map the title and slug of the post object to the custom fields if no value exists yet.
814
  if ( isset( $post->post_type ) && 'envira' == $post->post_type ) {
815
+ if ( empty( $settings['config']['title'] ) ) {
816
+ $settings['config']['title'] = trim( strip_tags( $post->post_title ) );
817
+ }
818
+ if ( empty( $settings['config']['slug'] ) ) {
819
+ $settings['config']['slug'] = sanitize_text_field( $post->post_name );
820
+ }
821
  }
822
 
823
  // Provide a filter to override settings.
readme.txt CHANGED
@@ -57,6 +57,9 @@ Also, I'm an <a href="https://thomasgriffin.io" rel="me" title="WordPress Develo
57
 
58
  == Changelog ==
59
 
 
 
 
60
  = 1.3.5.3 =
61
  * Fix: Close icon display on modals for WordPress 4.4
62
 
57
 
58
  == Changelog ==
59
 
60
+ = 1.3.5.4 =
61
+ * Fix: Gallery slug would not save when changed
62
+
63
  = 1.3.5.3 =
64
  * Fix: Close icon display on modals for WordPress 4.4
65