rankmath / seo-by-rank-math

Rank Math is a revolutionary WordPress SEO Plugin that combines the features of many SEO tools and lets you multiply your traffic in the easiest way possible :bulb: :chart_with_upwards_trend: →
https://rankmath.com
107 stars 52 forks source link

v1.0.62 — Schema Snippet class-primaryimage.php: `Undefined offset: 0` warning #75

Closed davidhund closed 3 years ago

davidhund commented 3 years ago

Describe the bug After updating to v1.0.62 My homepage (only) showed the warning:

Notice: Undefined offset: 0 
in /[...]/seo-by-rank-math/includes/modules/schema/snippets/class-primaryimage.php on line 38

https://github.com/rankmath/seo-by-rank-math/blame/master/includes/modules/schema/snippets/class-primaryimage.php#L38

The variable $image at this point is an Array with only a caption key and no value:

Array ( [caption] => )

Desktop (please complete the following information):

Additional context This is a MultiSite, Multi-Language-Press Wordpress 5.7 install. The error only occurs on the root site.com/

surajv commented 3 years ago

Fixed in v1.0.63