Skip to content

Commit

Permalink
fix: fatal error during new order email template
Browse files Browse the repository at this point in the history
  • Loading branch information
sabbir1991 committed Sep 9, 2020
1 parent a6a3562 commit 8d4dade
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions includes/Emails/VendorNewOrder.php
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,10 @@ public function init_form_fields() {
* @return bool
*/
public function prevent_sub_order_admin_email( $bool, $order ) {
if ( ! $order ) {
return $bool;
}

if ( $order->get_parent_id() ) {
return false;
}
Expand Down

0 comments on commit 8d4dade

Please sign in to comment.