Merge pull request #18 from cerc-io/dboreham/is-url-is-broken

Remove broken is-url dependency
This commit is contained in:
David Boreham 2022-12-21 13:50:32 -07:00 committed by GitHub
commit fd26bd88dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 1122 additions and 1020 deletions

View File

@ -7,7 +7,6 @@
"author": "",
"license": "UNLICENSED",
"devDependencies": {
"@types/is-url": "^1.2.30",
"@types/jest": "^27.4.1",
"@types/lodash": "^4.14.181",
"@types/semver": "^7.3.9",
@ -38,7 +37,6 @@
"ethers": "^5.6.2",
"evmosjs": "^0.2.5",
"graphql.js": "^0.6.8",
"is-url": "^1.2.4",
"js-sha256": "^0.9.0",
"js-yaml": "^3.14.1",
"jsonschema": "^1.4.0",

View File

@ -1,4 +1,3 @@
import isUrl from 'is-url';
import { sha256 } from 'js-sha256';
import { generatePostBodyBroadcast, BroadcastMode } from '@tharsis/provider';
import {
@ -122,13 +121,6 @@ export class Registry {
}
constructor(gqlUrl: string, restUrl: string = "", chainId: string = DEFAULT_CHAIN_ID) {
if (!isUrl(gqlUrl)) {
throw new Error('Path to a GQL endpoint should be provided.');
}
if (restUrl && !isUrl(restUrl)) {
throw new Error('REST endpoint is not a URL string.');
}
this._endpoints = {
rest: restUrl,

2132
yarn.lock

File diff suppressed because it is too large Load Diff