Fix komoditi notification sends notification day not in business

This commit is contained in:
Afiq Hamzah
2024-09-23 11:59:01 +08:00
parent f4609f469e
commit 2e4923262a
@@ -85,6 +85,11 @@ class WhatsappUnsoldCommodityNotification extends Job
$logger->info('End time is in the past');
return false;
}
if (! $isLatestKomoditiToday) {
$logger->info('No commodity is bought today, so technically no komoditi is sold and notifications will not be sent');
return false;
}
if ($isLatestKomoditiToday && $isAllKomoditiSold) {
$logger->info('All today komoditi is sold');