Add check in admin email for notify email address.
authorSteve Sutton <steve@gaslightmedia.com>
Mon, 5 Dec 2016 20:49:01 +0000 (15:49 -0500)
committerSteve Sutton <steve@gaslightmedia.com>
Mon, 5 Dec 2016 20:49:01 +0000 (15:49 -0500)
If empty then don't try to send out email.

classes/helper/notification.php

index 003aab0..85c7ae3 100644 (file)
@@ -152,6 +152,9 @@ class GlmMembersAdmin_event_notification extends GlmDataMembers
         $notify_to      = $settings['notify_to'];
         $notify_from    = $settings['notify_from'];
         $notify_message = $settings['notify_message'];
+        if ( !$notify_to ) {
+            return false;
+        }
 
         // Setup the Smarty Engine
         $smarty   = new smartyTemplateSupport();