fix(webstatement): perbaikan pengecekan variabel periode dalam processing data
Memperbaiki pengecekan variabel `$this->period` dari `empty()` menjadi `=== ''` pada berbagai job dalam modul Webstatement untuk memastikan logika validasi berfungsi dengan baik dan lebih eksplisit. - Job yang diperbaiki: - `ProcessAccountDataJob` - `ProcessArrangementDataJob` - `ProcessAtmTransactionJob` - `ProcessBillDetailDataJob` - `ProcessCategoryDataJob` - `ProcessCompanyDataJob` - `ProcessCustomerDataJob` - `ProcessDataCaptureDataJob` - `ProcessFundsTransferDataJob` - `ProcessStmtEntryDataJob` - `ProcessTellerDataJob` - Memastikan validasi terhadap variabel `$this->period` hanya memfokuskan pada apakah nilainya adalah string kosong (`''`). - Menambahkan kejelasan pada logging apabila periode tidak tersedia pada setiap job. - Perubahan ini bertujuan untuk menghindari potensi false negative pada pengecekan kondisi `empty()` yang dapat menyebabkan logika tidak berjalan sebagaimana mestinya. Signed-off-by: Daeng Deni Mardaeni <ddeni05@gmail.com>
This commit is contained in:
@@ -39,7 +39,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '') {
|
||||
Log::warning('No period provided for account data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '') {
|
||||
Log::warning('No period provided for arrangement data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
try {
|
||||
set_time_limit(24 * 60 * 60);
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for ATM transaction data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for bill detail data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for category data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for company data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for customer data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for data capture processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for funds transfer data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
$processedCount = 0;
|
||||
$errorCount = 0;
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for statement entry data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -146,7 +146,7 @@
|
||||
try {
|
||||
set_time_limit(24 * 60 * 60);
|
||||
|
||||
if (empty($this->period)) {
|
||||
if ($this->period === '')) {
|
||||
Log::warning('No period provided for teller data processing');
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user