*Use context var, not hns string
This commit is contained in:
parent
03062d3bfc
commit
05c4fc40d9
|
@ -133,7 +133,7 @@ export function rpcError(message: string): Promise<RpcError> {
|
|||
|
||||
export function validateChain(chain: string, handler: any) {
|
||||
return async (args: any, context: RpcContext) => {
|
||||
if (!context?.chain || "hns" !== context?.chain) {
|
||||
if (!context?.chain || chain !== context?.chain) {
|
||||
return rpcError(ERR_INVALID_CHAIN);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue