Instagram Feed - Version 2.4.3

Version Description

  • Fix: The opt-in notice to help improve the plugin was not dismissing as expected for some sites due to the admin JavaScript file being cached by the browser.
  • Fix: Disabled the About Us page plugin installation if using a version of WordPress earlier than 4.6.
Download this release

Release Info

Developer smashballoon
Plugin Icon 128x128 Instagram Feed
Version 2.4.3
Comparing to
See all releases

Code changes from version 2.4.2 to 2.4.3

README.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: smashballoon, craig-at-smash-balloon
3
  Tags: Instagram, Instagram feed, Instagram photos, Instagram widget, Instagram gallery
4
  Requires at least: 3.4
5
  Tested up to: 5.4
6
- Stable tag: 2.4.2
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -325,6 +325,10 @@ We understand that sometimes you need help, have issues or just have questions.
325
  * Plus more customization options added all the time!
326
 
327
  == Changelog ==
 
 
 
 
328
  = 2.4.2 =
329
  * New: To help us improve the plugin we've added the ability to opt-in to usage tracking so that we can understand what features and settings are being used, and which features matter to you the most. This is disabled by default and will only be enabled if you explictly choose to opt in. If opted in, the plugin will send a report in the background once per week with your plugin settings and basic information about your website environment. No personal or sensitive data is collected (such as email addresses, Instagram account information, license keys, etc). To enable or disable usage tracking at a later date use the setting at: Instagram Feed > Customize > Advanced > Misc > Enable Usage Tracking. See [here](https://smashballoon.com/instagram-feed/usage-tracking/) for more information.
330
  * Tweak: Added additional checks to make sure the HTTP protocol matches when using resized image URLs from the uploads folder.
3
  Tags: Instagram, Instagram feed, Instagram photos, Instagram widget, Instagram gallery
4
  Requires at least: 3.4
5
  Tested up to: 5.4
6
+ Stable tag: 2.4.3
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
325
  * Plus more customization options added all the time!
326
 
327
  == Changelog ==
328
+ = 2.4.3 =
329
+ * Fix: The opt-in notice to help improve the plugin was not dismissing as expected for some sites due to the admin JavaScript file being cached by the browser.
330
+ * Fix: Disabled the “About Us” page plugin installation if using a version of WordPress earlier than 4.6.
331
+
332
  = 2.4.2 =
333
  * New: To help us improve the plugin we've added the ability to opt-in to usage tracking so that we can understand what features and settings are being used, and which features matter to you the most. This is disabled by default and will only be enabled if you explictly choose to opt in. If opted in, the plugin will send a report in the background once per week with your plugin settings and basic information about your website environment. No personal or sensitive data is collected (such as email addresses, Instagram account information, license keys, etc). To enable or disable usage tracking at a later date use the setting at: Instagram Feed > Customize > Advanced > Misc > Enable Usage Tracking. See [here](https://smashballoon.com/instagram-feed/usage-tracking/) for more information.
334
  * Tweak: Added additional checks to make sure the HTTP protocol matches when using resized image URLs from the uploads folder.
inc/admin/actions.php CHANGED
@@ -1294,6 +1294,16 @@ add_action( 'admin_print_scripts', 'sbi_admin_hide_unrelated_notices' );
1294
  /* Usage */
1295
  add_action( 'admin_notices', 'sbi_usage_opt_in' );
1296
  function sbi_usage_opt_in() {
 
 
 
 
 
 
 
 
 
 
1297
  $cap = current_user_can( 'manage_instagram_feed_options' ) ? 'manage_instagram_feed_options' : 'manage_options';
1298
 
1299
  $cap = apply_filters( 'sbi_settings_pages_capability', $cap );
@@ -1313,8 +1323,8 @@ function sbi_usage_opt_in() {
1313
  <a target="_blank" rel="noopener noreferrer" href="https://smashballoon.com/instagram-feed/usage-tracking/"><?php echo __( 'More information', 'instagram-feed' ); ?></a>
1314
  </p>
1315
  <p>
1316
- <button class="button button-primary sb-opt-in"><?php echo __( 'Yes, I\'d like to help', 'instagram-feed' ); ?></button>
1317
- <button class="sb-no-usage-opt-out sbi-space-left button button-secondary"><?php echo __( 'No, thanks', 'instagram-feed' ); ?></button>
1318
  </p>
1319
 
1320
  </div>
1294
  /* Usage */
1295
  add_action( 'admin_notices', 'sbi_usage_opt_in' );
1296
  function sbi_usage_opt_in() {
1297
+ if ( isset( $_GET['trackingdismiss'] ) ) {
1298
+ $usage_tracking = get_option( 'sbi_usage_tracking', array( 'last_send' => 0, 'enabled' => false ) );
1299
+
1300
+ $usage_tracking['enabled'] = false;
1301
+
1302
+ update_option( 'sbi_usage_tracking', $usage_tracking, false );
1303
+
1304
+ return;
1305
+ }
1306
+
1307
  $cap = current_user_can( 'manage_instagram_feed_options' ) ? 'manage_instagram_feed_options' : 'manage_options';
1308
 
1309
  $cap = apply_filters( 'sbi_settings_pages_capability', $cap );
1323
  <a target="_blank" rel="noopener noreferrer" href="https://smashballoon.com/instagram-feed/usage-tracking/"><?php echo __( 'More information', 'instagram-feed' ); ?></a>
1324
  </p>
1325
  <p>
1326
+ <a href="<?php echo admin_url('admin.php?page=sb-instagram-feed&trackingdismiss=1') ?>" class="button button-primary sb-opt-in"><?php echo __( 'Yes, I\'d like to help', 'instagram-feed' ); ?></a>
1327
+ <a href="<?php echo admin_url('admin.php?page=sb-instagram-feed&trackingdismiss=1') ?>" class="sb-no-usage-opt-out sbi-space-left button button-secondary"><?php echo __( 'No, thanks', 'instagram-feed' ); ?></a>
1328
  </p>
1329
 
1330
  </div>
inc/admin/class-sbi-about.php CHANGED
@@ -307,7 +307,9 @@ class SB_Instagram_About {
307
  */
308
  protected function output_about_addons() {
309
 
310
- if ( ! current_user_can( 'manage_instagram_feed_options' ) || version_compare( PHP_VERSION, '5.3.0' ) <= 0 ) {
 
 
311
  return;
312
  }
313
 
307
  */
308
  protected function output_about_addons() {
309
 
310
+ if ( ! current_user_can( 'manage_instagram_feed_options' ) || version_compare( PHP_VERSION, '5.3.0' ) <= 0
311
+ || version_compare( PHP_VERSION, '5.3.0' ) <= 0
312
+ || version_compare( get_bloginfo('version'), '4.6' , '<' ) ){
313
  return;
314
  }
315
 
instagram-feed.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Smash Balloon Instagram Feed
4
  Plugin URI: https://smashballoon.com/instagram-feed
5
  Description: Display beautifully clean, customizable, and responsive Instagram feeds.
6
- Version: 2.4.2
7
  Author: Smash Balloon
8
  Author URI: https://smashballoon.com/
9
  License: GPLv2 or later
@@ -23,7 +23,7 @@ along with this program; if not, write to the Free Software
23
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24
  */
25
  if ( ! defined( 'SBIVER' ) ) {
26
- define( 'SBIVER', '2.4.2' );
27
  }
28
  // Db version.
29
  if ( ! defined( 'SBI_DBVERSION' ) ) {
@@ -117,7 +117,8 @@ if ( function_exists( 'sb_instagram_feed_init' ) ) {
117
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/main.php';
118
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/class-sbi-about.php';
119
 
120
- if ( version_compare( PHP_VERSION, '5.3.0' ) >= 0 ) {
 
121
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/addon-functions.php';
122
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/PluginSilentUpgrader.php';
123
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/PluginSilentUpgraderSkin.php';
3
  Plugin Name: Smash Balloon Instagram Feed
4
  Plugin URI: https://smashballoon.com/instagram-feed
5
  Description: Display beautifully clean, customizable, and responsive Instagram feeds.
6
+ Version: 2.4.3
7
  Author: Smash Balloon
8
  Author URI: https://smashballoon.com/
9
  License: GPLv2 or later
23
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24
  */
25
  if ( ! defined( 'SBIVER' ) ) {
26
+ define( 'SBIVER', '2.4.3' );
27
  }
28
  // Db version.
29
  if ( ! defined( 'SBI_DBVERSION' ) ) {
117
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/main.php';
118
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/class-sbi-about.php';
119
 
120
+ if ( version_compare( PHP_VERSION, '5.3.0' ) >= 0
121
+ && version_compare( get_bloginfo( 'version' ), '4.6' , '>=' ) ) {
122
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/addon-functions.php';
123
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/PluginSilentUpgrader.php';
124
  require_once trailingslashit( SBI_PLUGIN_DIR ) . 'inc/admin/PluginSilentUpgraderSkin.php';