From 8bc21740b13801b739eddb22bdb3ecd40a0f8d3f Mon Sep 17 00:00:00 2001 From: WL Support <65345103+WLsupport@users.noreply.github.com> Date: Thu, 21 Apr 2022 13:45:28 +0200 Subject: [PATCH] fix regression from #130 in DNS1D.php in #130 the regex pattern for C128C was broken this reverts it to its prior working state --- src/Milon/Barcode/DNS1D.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Milon/Barcode/DNS1D.php b/src/Milon/Barcode/DNS1D.php index 6782103..669e3f9 100644 --- a/src/Milon/Barcode/DNS1D.php +++ b/src/Milon/Barcode/DNS1D.php @@ -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;