be consistent in our blockchain name, use is_subdomain() for determining if a name is a subdomain

This commit is contained in:
Jude Nelson
2018-02-14 17:41:59 -05:00
parent fc56067c2c
commit b0062e591f

View File

@@ -1123,7 +1123,7 @@ def cli_whois(args, config_path=CONFIG_PATH):
'zonefile_txt': zonefile_txt,
'zonefile_hash': storage.get_zonefile_data_hash(zonefile_txt),
'address': record['address'],
'blockchain': 'bitcoind',
'blockchain': 'bitcoin',
'last_txid': record['txid'],
}
return result
@@ -4189,15 +4189,9 @@ def cli_lookup_snv(args, config_path=CONFIG_PATH):
name = str(args.name)
error = check_valid_name(name)
if error:
res = blockstackd_scripts.is_address_subdomain(name)
# res = subdomains.is_address_subdomain(name)
res = blockstackd_scripts.is_subdomain(name)
if res:
subdomain, domain = res[1]
if subdomain:
return {'error': 'SNV lookup on subdomains is not yet supported'}
name = domain
return {'error': 'SNV lookup on subdomains is not yet supported'}
else:
return {'error': error}