From fcd0b03e7ef8c8884470256de5d60bebe497f923 Mon Sep 17 00:00:00 2001 From: claudiosmweb Date: Mon, 12 May 2014 15:55:53 -0300 Subject: [PATCH] normalized the woocommerce_email_attachments filter return type --- includes/class-wc-emails.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/class-wc-emails.php b/includes/class-wc-emails.php index 8d1538ddfe0..fdd9dde8d5e 100644 --- a/includes/class-wc-emails.php +++ b/includes/class-wc-emails.php @@ -343,7 +343,7 @@ class WC_Emails { $headers = apply_filters('woocommerce_email_headers', '', 'low_stock', $product); // Attachments - $attachments = apply_filters('woocommerce_email_attachments', '', 'low_stock', $product); + $attachments = apply_filters('woocommerce_email_attachments', array(), 'low_stock', $product); // Send the mail wp_mail( get_option('woocommerce_stock_email_recipient'), $subject, $message, $headers, $attachments ); @@ -375,7 +375,7 @@ class WC_Emails { $headers = apply_filters('woocommerce_email_headers', '', 'no_stock', $product); // Attachments - $attachments = apply_filters('woocommerce_email_attachments', '', 'no_stock', $product); + $attachments = apply_filters('woocommerce_email_attachments', array(), 'no_stock', $product); // Send the mail wp_mail( get_option('woocommerce_stock_email_recipient'), $subject, $message, $headers, $attachments ); @@ -420,7 +420,7 @@ class WC_Emails { $headers = apply_filters('woocommerce_email_headers', '', 'backorder', $args); // Attachments - $attachments = apply_filters('woocommerce_email_attachments', '', 'backorder', $args); + $attachments = apply_filters('woocommerce_email_attachments', array(), 'backorder', $args); // Send the mail wp_mail( get_option('woocommerce_stock_email_recipient'), $subject, $message, $headers, $attachments );