Add public_key variable where it was undefined

Previously the public_key variable is being referenced but it is never
set in this API call. This allows the correct functionality to occur
when the public_key query parameter is set.
This commit is contained in:
pxgamer
2018-11-05 11:58:44 +00:00
parent 6252d4e3fe
commit be078f910f

View File

@@ -203,6 +203,7 @@ if ($q == "getAddress") {
*/
$account = san($data['account']);
$public_key = san($data['public_key'] ?? '');
if (!empty($public_key) && strlen($public_key) < 32) {
api_err("Invalid public key");
}