Skip to content

Commit

Permalink
Set correct error log severity
Browse files Browse the repository at this point in the history
  • Loading branch information
marianhlavac committed Nov 18, 2023
1 parent c8f3103 commit 5316be4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion vatchecker.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
exit;
}

const ERROR_SEVERITY = 3;

class Vatchecker extends Module
{
/**
Expand Down Expand Up @@ -836,7 +838,7 @@ protected function checkVies( $countryCode, $vatNumber )
$return['valid'] = null;
}

PrestaShopLogger::addLog( 'Vatchecker: ' . implode( ', ', $params ) . ' > ' . $e->getMessage() );
PrestaShopLogger::addLog( 'VAT check failed! (params: ' . implode( ', ', $params ) . ' , error: ' . $e->getMessage() . ')', ERROR_SEVERITY );
}

$cache[ $cache_key ] = $return;
Expand Down

0 comments on commit 5316be4

Please sign in to comment.