Skip to content

Commit

Permalink
fix regression from milon#130 in DNS1D.php
Browse files Browse the repository at this point in the history
in milon#130 the regex pattern for C128C was broken
this reverts it to its prior working state
  • Loading branch information
WLsupport committed Apr 21, 2022
1 parent 457eac9 commit 8bc2174
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Milon/Barcode/DNS1D.php
Expand Up @@ -1231,7 +1231,7 @@ protected function barcode_c128($code, $type = '') {
}
for ($i = 0; $i < $len; $i+=2) {
$chrnum = $code[$i] . $code[$i + 1];
if (preg_match('/([0-9][2])/', $chrnum) > 0) {
if (preg_match('/([0-9]{2})/', $chrnum) > 0) {
$code_data[] = intval($chrnum);
} else {
return false;
Expand Down

0 comments on commit 8bc2174

Please sign in to comment.