Skip to content

Commit

Permalink
fix log isset errors
Browse files Browse the repository at this point in the history
  • Loading branch information
jared970 committed May 25, 2021
1 parent 1db24b0 commit 209cf00
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/Solution.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,13 @@ public static function verifyHEXstr($hex = '', $str_len = 64): bool {
}

public function parseLink(): string {
$emptyErr = "empty address given";
if(!isset($_GET['address'])) {
return $emptyErr;
}
$address = self::dataFilter($_GET['address']);
if($address == '') {
return "empty address given";
return $emptyErr;
}
if(! self::verifyHEXstr($address)) {
return "invalid address given";
Expand All @@ -50,6 +54,9 @@ public function parseLink(): string {
}

public function parseDataForQR(): string {
if(!isset($_GET['address'])) {
return '';
}
$addressShort = self::dataFilter($_GET['address']);
$address = $this->addressDecode($addressShort);
return $address;
Expand Down

0 comments on commit 209cf00

Please sign in to comment.