From a171dca4da04cd9c3fbeb67cb0fe4f9f727bcc52 Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Thu, 3 Sep 2020 14:19:12 +0200 Subject: [PATCH 1/2] update and expose default options --- modules/client/src/default.ts | 6 +++--- modules/client/src/index.ts | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/modules/client/src/default.ts b/modules/client/src/default.ts index 01127760c4..6ff781ae32 100644 --- a/modules/client/src/default.ts +++ b/modules/client/src/default.ts @@ -5,7 +5,7 @@ import { getRandomPrivateKey } from "@connext/utils"; const CONNEXT_DEFAULT_SIGNER_KEY = "CONNEXT_DEFAULT_SIGNER"; const removeUndefinedFields = (obj: T): T => { - Object.keys(obj).forEach(key => typeof obj[key] === "undefined" && delete obj[key]); + Object.keys(obj).forEach((key) => typeof obj[key] === "undefined" && delete obj[key]); return obj; }; @@ -21,7 +21,7 @@ const getGeneratedSigner = (): string => { return signer; }; -const getUrlOptions = (network: string): { ethProviderUrl: string; nodeUrl: string } => { +export const getUrlOptions = (network: string): { ethProviderUrl: string; nodeUrl: string } => { let urlOptions; if (network.toLowerCase() === "localhost") { @@ -31,7 +31,7 @@ const getUrlOptions = (network: string): { ethProviderUrl: string; nodeUrl: stri network.toLowerCase() === "mainnet" ? "indra.connext.network" : network.toLowerCase() === "rinkeby" - ? "rinkeby.indra.connext.network" + ? "staging.indra.connext.network" : null; if (!baseUrl) { throw new Error(`Provided network (${network.toLowerCase()}) is not supported`); diff --git a/modules/client/src/index.ts b/modules/client/src/index.ts index f6ecc647c3..dfda23ff4c 100644 --- a/modules/client/src/index.ts +++ b/modules/client/src/index.ts @@ -1,8 +1,9 @@ import "core-js/stable"; import "regenerator-runtime/runtime"; import * as utils from "@connext/utils"; +import { getUrlOptions, getDefaultOptions } from "./default"; import { connect } from "./connect"; import { ConnextClient } from "./connext"; -export { ConnextClient, connect, utils }; +export { ConnextClient, connect, utils, getUrlOptions, getDefaultOptions }; From 987b89dcc2e49a7fb2027871a66693fd229e9b02 Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Thu, 3 Sep 2020 14:46:12 +0200 Subject: [PATCH 2/2] plock --- package-lock.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package-lock.json b/package-lock.json index d336cd5f91..7497a82853 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "indra", - "version": "7.3.12", + "version": "7.3.13", "lockfileVersion": 1, "requires": true, "dependencies": {