Skip to content

Commit

Permalink
Merge pull request #331 from NovemBit/develop
Browse files Browse the repository at this point in the history
Fix php warning. Fixes #330
  • Loading branch information
helen authored Mar 6, 2019
2 parents f8f4490 + f242f55 commit 1ac45d0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion includes/utils.php
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,9 @@ function set_media( $post_id, $media ) {
}

// Transfer all meta
set_meta( $image_id, $media_item['meta'] );
if ( isset( $media_item['meta'] ) ) {
set_meta( $image_id, $media_item['meta'] );
}

// Transfer post properties
wp_update_post(
Expand Down

0 comments on commit 1ac45d0

Please sign in to comment.