From 100ffabf50f48a193a078e53684b37fdf78720c3 Mon Sep 17 00:00:00 2001 From: Andy Feliciotti Date: Sun, 26 May 2024 10:24:01 -0500 Subject: [PATCH] 1.3.15 --- mightyshare.php | 12 ++++++------ readme.txt | 5 ++++- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/mightyshare.php b/mightyshare.php index 75e2aaa..e8b4a0f 100644 --- a/mightyshare.php +++ b/mightyshare.php @@ -3,7 +3,7 @@ * Plugin Name: MightyShare * Plugin URI: https://mightyshare.io/wordpress/ * Description: Automatically generate social share preview images with MightyShare! - * Version: 1.3.14 + * Version: 1.3.15 * Text Domain: mightyshare * Author: MightyShare * Author URI: https://mightyshare.io @@ -13,7 +13,7 @@ exit; // Exit if accessed directly. } -define( 'MIGHTYSHARE_VERSION', '1.3.14' ); +define( 'MIGHTYSHARE_VERSION', '1.3.15' ); define( 'MIGHTYSHARE_DIR_URL', plugin_dir_url( __FILE__ ) ); define( 'MIGHTYSHARE_DIR_URI', plugin_dir_path( __FILE__ ) ); @@ -1035,10 +1035,10 @@ public function get_mightyshare_post_details() { } if ( $wp_query->is_archive && ! empty( $template_parts ) ) { - $returned_template_parts['ID'] = $template_parts->term_id; - $returned_template_parts['title'] = $template_parts->name; - $returned_template_parts['description'] = $template_parts->category_description; - $returned_template_parts['type'] = $template_parts->taxonomy; + $returned_template_parts['ID'] = isset($template_parts->term_id) ? $template_parts->term_id : ''; + $returned_template_parts['title'] = isset($template_parts->name) ? $template_parts->name : ''; + $returned_template_parts['description'] = isset($template_parts->category_description) ? $template_parts->category_description : ''; + $returned_template_parts['type'] = isset($template_parts->taxonomy) ? $template_parts->taxonomy : ''; $returned_template_parts['object_type'] = 'taxonomies'; } diff --git a/readme.txt b/readme.txt index c758293..c6c40a4 100644 --- a/readme.txt +++ b/readme.txt @@ -5,7 +5,7 @@ Tags: Social Preview, Open Graph, Social Media, Twitter Card, Open Graph Images Requires at least: 5.4 Tested up to: 6.5 Requires PHP: 7.4 -Stable tag: 1.3.14 +Stable tag: 1.3.15 License: GPLv3 License URI: http://www.gnu.org/licenses/gpl.html @@ -70,6 +70,9 @@ If you are using an SEO plugin be sure to have a default image set for the type == Changelog == += 1.3.15 = +* Bug fix for PHP warning. + = 1.3.14 = * Bug fix for PHP warning.