Skip to content

Commit

Permalink
Update Borica.php
Browse files Browse the repository at this point in the history
  • Loading branch information
howkins authored Jan 4, 2022
1 parent 1102a11 commit 0241fa8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Borica.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,11 @@ public static function generateMac(array $data, bool $isResponse, bool $is_mac_e

public static function generateMacExtended(array $data, bool $isResponse)
{
$macFields = $isResponse ? Mac::EXTENDED_RESPONSE_FIELDS : MAC::EXTENDED_REQUEST_FIELDS;

$message = '';
if(!isset($data['TRTYPE'])){
return $message;
}
$macFields = $isResponse ? Mac::EXTENDED_RESPONSE_FIELDS : MAC::EXTENDED_REQUEST_FIELDS;

foreach ($macFields[$data['TRTYPE']] as $field) {
$value = isset($data[$field]) ? $data[$field] : null;
Expand Down

0 comments on commit 0241fa8

Please sign in to comment.