Skip to content

Commit

Permalink
Avoid Fatals when the class does not exist (like on WordPress.com)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeherve committed Apr 15, 2019
1 parent 5410fad commit 2b81a34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion 3rd-party/class.jetpack-amp-support.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public static function amp_post_template_metadata( $metadata, $post ) {
*/
private static function add_site_icon_to_metadata( $metadata ) {
$size = 60;
$site_icon_url = Jetpack_Sync_Functions::site_icon_url( $size );
$site_icon_url = class_exists( 'Jetpack_Sync_Functions' ) ? Jetpack_Sync_Functions::site_icon_url( $size ) : '';

if ( function_exists( 'blavatar_domain' ) ) {
$metadata['publisher']['logo'] = array(
Expand Down

0 comments on commit 2b81a34

Please sign in to comment.