From ec79f47cefcd4132319efc63bdb630899a9a58f3 Mon Sep 17 00:00:00 2001 From: Aleksandr Kraiz Date: Sun, 24 Apr 2022 01:47:12 +0400 Subject: [PATCH] Minor fix --- src/OrionUnit/index.ts | 2 +- src/services/OrionBlockchain/index.ts | 6 +----- tsconfig.json | 16 ++++++++-------- 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/src/OrionUnit/index.ts b/src/OrionUnit/index.ts index 026ac67..02806d7 100644 --- a/src/OrionUnit/index.ts +++ b/src/OrionUnit/index.ts @@ -36,7 +36,7 @@ export default class OrionUnit { this.env = env; this.apiUrl = apiUrl; - this.orionBlockchain = new OrionBlockchain(apiUrl, chainId); + this.orionBlockchain = new OrionBlockchain(apiUrl); this.orionAggregator = new OrionAggregator(apiUrl, chainId); this.priceFeed = new PriceFeed(apiUrl); this.exchange = new Exchange(this); diff --git a/src/services/OrionBlockchain/index.ts b/src/services/OrionBlockchain/index.ts index c3416c0..8b3ef95 100644 --- a/src/services/OrionBlockchain/index.ts +++ b/src/services/OrionBlockchain/index.ts @@ -9,7 +9,6 @@ import { import { OrionBlockchainSocketIO } from './ws'; import redeemOrderSchema from '../OrionAggregator/schemas/redeemOrderSchema'; import { sourceAtomicHistorySchema, targetAtomicHistorySchema } from './schemas/atomicHistorySchema'; -import { SupportedChainId } from '../../types'; import { utils } from '../..'; interface IAdminAuthHeaders { @@ -54,10 +53,7 @@ class OrionBlockchain { readonly ws: OrionBlockchainSocketIO; - constructor( - apiUrl: string, - chainId: SupportedChainId, - ) { + constructor(apiUrl: string) { this.apiUrl = apiUrl; this.ws = new OrionBlockchainSocketIO(`https://${apiUrl}/`); } diff --git a/tsconfig.json b/tsconfig.json index b0701ef..55c01b6 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -20,10 +20,10 @@ // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ /* Language and Environment */ - "target": "ES2015", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ - "lib": [ - "ES2015", - ], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ + "target": "ESNext", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ + // "lib": [ + // "", + // ], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ // "jsx": "preserve", /* Specify what JSX code is generated. */ // "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */ // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ @@ -34,7 +34,7 @@ // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ /* Modules */ - "module": "ES2015", /* Specify what module code is generated. */ + "module": "CommonJS", /* Specify what module code is generated. */ // "rootDir": "./", /* Specify the root folder within your source files. */ "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */ // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */ @@ -80,7 +80,7 @@ "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */ /* Type Checking */ "strict": true, /* Enable all strict type-checking options. */ - // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied `any` type.. */ + "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied `any` type.. */ // "strictNullChecks": true, /* When type checking, take into account `null` and `undefined`. */ // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ // "strictBindCallApply": true, /* Check that the arguments for `bind`, `call`, and `apply` methods match the original function. */ @@ -88,8 +88,8 @@ // "noImplicitThis": true, /* Enable error reporting when `this` is given the type `any`. */ // "useUnknownInCatchVariables": true, /* Type catch clause variables as 'unknown' instead of 'any'. */ // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ - // "noUnusedLocals": true, /* Enable error reporting when a local variables aren't read. */ - // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read */ + "noUnusedLocals": true, /* Enable error reporting when a local variables aren't read. */ + "noUnusedParameters": true, /* Raise an error when a function parameter isn't read */ // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */