diff --git a/.env.example b/.env.example index 3fd682f..c8c57fd 100644 --- a/.env.example +++ b/.env.example @@ -37,7 +37,7 @@ MAIL_ENCRYPTION=tls MAIL_SENDFROM=null MAIL_SENDTO=null -MAILCHIMP_APIKEY= -MAILCHIMP_LISTID= +MAILCHIMP_APIKEY=null +MAILCHIMP_LISTID=null REGISTRATION=true diff --git a/app/Http/Controllers/SubscriptionController.php b/app/Http/Controllers/SubscriptionController.php index 0ada1e2..96e244f 100644 --- a/app/Http/Controllers/SubscriptionController.php +++ b/app/Http/Controllers/SubscriptionController.php @@ -18,7 +18,7 @@ class SubscriptionController extends Controller { $lname = preg_match('/. ./', $name) === 1 ? preg_replace('/^[^ ][^ ]* /', '', $name) : ''; $email = $request['email']; - if (env('MAILCHIMP_APIKEY', '') != '' && env('MAILCHIMP_LISTID', '') != '') { + if (env('MAILCHIMP_APIKEY') != null && env('MAILCHIMP_LISTID') != null) { // Submit the subscription request Newsletter::subscribeOrUpdate($email, [ 'FNAME' => $fname,