Skip to content

Commit db8627d

Browse files
committed
2 parents 12164a5 + c73d004 commit db8627d

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

classes/class-swsales-metaboxes.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -706,6 +706,11 @@ public static function save_swsales_metaboxes( $post_id, $post ) {
706706
return;
707707
}
708708

709+
// Bail if we're moving from trashed to published.
710+
if ( isset( $_REQUEST['action'] ) && 'untrash' === $_REQUEST['action'] ) {
711+
return;
712+
}
713+
709714
// Add nonce for security and authentication.
710715
$nonce_name = isset( $_POST['custom_nonce'] ) ? sanitize_text_field( $_POST['custom_nonce'] ) : '';
711716
$nonce_action = 'custom_nonce_action';

0 commit comments

Comments
 (0)