*Update dist

This commit is contained in:
Derrick Hammer 2022-08-18 18:50:54 -04:00
parent ef787eba13
commit 1c9b882642
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
2 changed files with 14 additions and 0 deletions

View File

@ -1,8 +1,13 @@
import { DNSResult, ResolverOptions } from "@lumeweb/resolver-common"; import { DNSResult, ResolverOptions } from "@lumeweb/resolver-common";
import { RpcNetwork } from "@lumeweb/kernel-rpc-client";
export declare class ResolverRegistry { export declare class ResolverRegistry {
private _rpcNetwork;
constructor(network: RpcNetwork);
get rpcNetwork(): RpcNetwork;
resolve( resolve(
domain: string, domain: string,
options?: ResolverOptions, options?: ResolverOptions,
bypassCache?: boolean bypassCache?: boolean
): Promise<DNSResult>; ): Promise<DNSResult>;
} }
export { RpcNetwork };

View File

@ -1,6 +1,14 @@
import { DNS_RECORD_TYPE, resolverError, } from "@lumeweb/resolver-common"; import { DNS_RECORD_TYPE, resolverError, } from "@lumeweb/resolver-common";
import { resolve } from "@lumeweb/kernel-dns-client"; import { resolve } from "@lumeweb/kernel-dns-client";
import { RpcNetwork } from "@lumeweb/kernel-rpc-client";
export class ResolverRegistry { export class ResolverRegistry {
_rpcNetwork;
constructor(network) {
this._rpcNetwork = network;
}
get rpcNetwork() {
return this._rpcNetwork;
}
async resolve(domain, options = { type: DNS_RECORD_TYPE.DEFAULT }, bypassCache = false) { async resolve(domain, options = { type: DNS_RECORD_TYPE.DEFAULT }, bypassCache = false) {
let result; let result;
try { try {
@ -12,3 +20,4 @@ export class ResolverRegistry {
return result; return result;
} }
} }
export { RpcNetwork };