Skip to content

Commit

Permalink
style: fix lint error
Browse files Browse the repository at this point in the history
  • Loading branch information
AllenLiuxt committed Mar 17, 2022
1 parent 0d378f8 commit 262b1fb
Show file tree
Hide file tree
Showing 23 changed files with 94 additions and 94 deletions.
8 changes: 4 additions & 4 deletions src/HTTP/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/IPC/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/WS/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/abi/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
6 changes: 3 additions & 3 deletions src/accountBlock/account.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import { Hex, Address, TokenId, BigInt, Base64, Int32, Uint8, Uint32, Uint256, B


class AccountClass {
readonly address: Address
private provider: ProviderType
private privateKey: Hex
readonly address: Address;
private provider: ProviderType;
private privateKey: Hex;

constructor(address: Address) {
const err = checkParams({ address }, ['address'], [{
Expand Down
4 changes: 2 additions & 2 deletions src/accountBlock/accountBlock.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ class AccountBlockClass {
publicKey?: Base64;
_toAddress?: Address;

private privateKey: Hex
private provider: ProviderType
private privateKey: Hex;
private provider: ProviderType;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
14 changes: 7 additions & 7 deletions src/accountBlock/receiveAccountBlockTask.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ import { Address, Hex, ProviderType, AccountBlockBlock } from './type';
export class ReceiveAccountBlockTask {
address: Address;

private provider: ProviderType
private sign: Function | undefined | null
private privateKey: Hex | undefined | null
private _account: Account
private _timer: any
private successCB: Function
private errorCB: Function
private provider: ProviderType;
private sign: Function | undefined | null;
private privateKey: Hex | undefined | null;
private _account: Account;
private _timer: any;
private successCB: Function;
private errorCB: Function;

constructor({ address, provider, privateKey, sign }: {
address: Address; provider: ProviderType; privateKey?: Hex; sign?: Function;
Expand Down
8 changes: 4 additions & 4 deletions src/accountBlock/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/communication/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/constant/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/error/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/keystore/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/utils/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
10 changes: 5 additions & 5 deletions src/viteAPI/eventEmitter.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { ProviderType } from './type';

class EventEmitter {
readonly id: string
readonly isSubscribe: boolean
private provider: ProviderType
private timeLoop: any
private callback: Function
readonly id: string;
readonly isSubscribe: boolean;
private provider: ProviderType;
private timeLoop: any;
private callback: Function;

constructor(id: string, provider: ProviderType, isSubscribe: boolean) {
this.id = id;
Expand Down
2 changes: 1 addition & 1 deletion src/viteAPI/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import Provider from './provider';


class ViteAPIClass extends Provider {
private customTransactionType: Object
private customTransactionType: Object;

constructor(provider: any, onInitCallback: Function) {
super(provider, onInitCallback);
Expand Down
12 changes: 6 additions & 6 deletions src/viteAPI/provider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ import EventEmitter from './eventEmitter';


class ProviderClass {
isConnected: Boolean = false
private _provider: any
private subscriptionList: {[id:number]:EventEmitter} = {}
private subscriptionId = 0
private requestList: {[id:number]:()=>void} = {}
private requestId = 0
isConnected: Boolean = false;
private _provider: any;
private subscriptionList: {[id:number]:EventEmitter} = {};
private subscriptionId = 0;
private requestList: {[id:number]:()=>void} = {};
private requestId = 0;

constructor(provider: any, onInitCallback: Function) {
this._provider = provider;
Expand Down
8 changes: 4 additions & 4 deletions src/viteAPI/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
8 changes: 4 additions & 4 deletions src/vitejs/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ export declare class ProviderType {
}

export declare class ViteAPI extends ProviderType {
transactionType: Object
transactionType: Object;

constructor(provider: any, onInitCallback: Function)

Expand Down Expand Up @@ -333,10 +333,10 @@ export declare class AccountBlockClassType {
nonceHex: Hex;
hash: Hex;

isRequestBlock: Boolean
isResponseBlock: Boolean
isRequestBlock: Boolean;
isResponseBlock: Boolean;

accountBlock: AccountBlockBlock
accountBlock: AccountBlockBlock;

constructor({ blockType, address, fee, data, sendBlockHash, amount, toAddress, tokenId }: {
blockType: BlockType;
Expand Down
Loading

0 comments on commit 262b1fb

Please sign in to comment.