Bostjan Rihter 7 년 전
부모
커밋
a08d080d96
2개의 변경된 파일8개의 추가작업 그리고 7개의 파일을 삭제
  1. 3 2
      src/QRCode.php
  2. 5 5
      tests/QRCodeTest.php

+ 3 - 2
src/QRCode.php

@@ -161,8 +161,9 @@ class QRCode{
 	 * @throws \chillerlan\QRCode\Data\QRCodeDataException
 	 */
 	public function getMatrix(string $data):QRMatrix {
-        //NOTE: input sanitization should be done outside
-        //$data = trim($data);
+		//NOTE: input sanitization should be done outside
+		//$data = trim($data);
+		
 		if(empty($data)){
 			throw new QRCodeDataException('QRCode::getMatrix() No data given.');
 		}

+ 5 - 5
tests/QRCodeTest.php

@@ -94,12 +94,12 @@ class QRCodeTest extends QRTestAbstract{
 		$this->qrcode->getMatrix('');
 	}
 
-    public function testTrim() {
-        $m1 = $this->qrcode->getMatrix('hello');
-        $m2 = $this->qrcode->getMatrix('hello '); // added space
+	public function testTrim() {
+		$m1 = $this->qrcode->getMatrix('hello');
+		$m2 = $this->qrcode->getMatrix('hello '); // added space
 
-        $this->assertNotEquals($m1, $m2);
-    }
+		$this->assertNotEquals($m1, $m2);
+	}
 
 	public function testImageTransparencyBGDefault(){
 		$this->qrcode = $this->reflection->newInstanceArgs([new QROptions(['imageTransparencyBG' => 'foo'])]);