diff --git a/app/Services/Barobill/BarobillUsageService.php b/app/Services/Barobill/BarobillUsageService.php index 3ac55fd8..8bcc2534 100644 --- a/app/Services/Barobill/BarobillUsageService.php +++ b/app/Services/Barobill/BarobillUsageService.php @@ -194,9 +194,13 @@ protected function getBankAccountCount(BarobillMember $member, string $startDate } // 객체에 계좌 목록이 있으면 if (is_object($result['data'])) { - // BankAccountInfoEx 배열이 있는 경우 - if (isset($result['data']->BankAccountInfoEx)) { - $accounts = $result['data']->BankAccountInfoEx; + // GetBankAccountEx 응답: BankAccount 또는 BankAccountEx 배열 + if (isset($result['data']->BankAccount)) { + $accounts = $result['data']->BankAccount; + return is_array($accounts) ? count($accounts) : 1; + } + if (isset($result['data']->BankAccountEx)) { + $accounts = $result['data']->BankAccountEx; return is_array($accounts) ? count($accounts) : 1; } } @@ -237,9 +241,9 @@ protected function getCardCount(BarobillMember $member, string $startDate, strin } // 객체에 카드 목록이 있으면 if (is_object($result['data'])) { - // CardInfoEx2 배열이 있는 경우 - if (isset($result['data']->CardInfoEx2)) { - $cards = $result['data']->CardInfoEx2; + // GetCardEx2 응답: CardEx 배열 + if (isset($result['data']->CardEx)) { + $cards = $result['data']->CardEx; return is_array($cards) ? count($cards) : 1; } }