Set subscriber to null instead of false

[MAILPOET-2950]
This commit is contained in:
Amine Ben hammou
2020-05-28 15:24:51 +02:00
committed by Veljko V
parent 419a50e10a
commit f5b836e898
2 changed files with 18 additions and 14 deletions

View File

@@ -17,7 +17,7 @@ class SubscriberSegment extends Model {
}
public static function unsubscribeFromSegments($subscriber, $segmentIds = []) {
if ($subscriber === false) return false;
if (!$subscriber) return false;
// Reset confirmation emails count, so user can resubscribe
$subscriber->countConfirmations = 0;