:octocat:

This commit is contained in:
codemasher
2020-02-19 15:53:42 +01:00
parent 66466432db
commit 8c0a79bae8
2 changed files with 1 additions and 3 deletions
-2
View File
@@ -47,11 +47,9 @@ class Number extends QRDataAbstract{
if($this->strlen - $i === 1){
$this->bitBuffer->put($this->parseInt(substr($data, $i, $i + 1)), 4);
}
// @codeCoverageIgnoreStart
elseif($this->strlen - $i === 2){
$this->bitBuffer->put($this->parseInt(substr($data, $i, $i + 2)), 7);
}
// @codeCoverageIgnoreEnd
}
+1 -1
View File
@@ -45,7 +45,7 @@ class BitBuffer{
public function put(int $num, int $length):BitBuffer{
for($i = 0; $i < $length; $i++){
$this->putBit(($num >> ($length - $i - 1))&1 === 1);
$this->putBit((($num >> ($length - $i - 1)) & 1) === 1);
}
return $this;