mirror of
https://github.com/pezkuwichain/pezkuwi-ui.git
synced 2026-06-13 23:51:01 +00:00
Typescript-eslint 2 (#193)
This commit is contained in:
@@ -25,7 +25,7 @@ function callNext (current: SubjectInfo, subject: BehaviorSubject<SubjectInfo>,
|
||||
subject.next(filtered);
|
||||
}
|
||||
|
||||
export default function genericSubject (keyCreator: (address: string) => string, withTest: boolean = false): AddressSubject {
|
||||
export default function genericSubject (keyCreator: (address: string) => string, withTest = false): AddressSubject {
|
||||
let current: SubjectInfo = {};
|
||||
const subject = new BehaviorSubject({});
|
||||
const next = (): void => callNext(current, subject, withTest);
|
||||
|
||||
@@ -9,7 +9,7 @@ import { isUndefined } from '@polkadot/util';
|
||||
|
||||
import KeyPair from './KeyPair';
|
||||
|
||||
export default function createItem (address: string, _name?: string, isUppercase: boolean = true): KeyringSectionOption {
|
||||
export default function createItem (address: string, _name?: string, isUppercase = true): KeyringSectionOption {
|
||||
const name = isUndefined(_name)
|
||||
? (
|
||||
(address.length > 15)
|
||||
|
||||
@@ -47,7 +47,7 @@ export default class ExtensionStore implements KeyringStore {
|
||||
|
||||
public set (key: string, value: KeyringJson, cb?: () => void): void {
|
||||
// shortcut, don't save testing accounts in extension storage
|
||||
if (key.indexOf('account:') === 0 && value.meta && value.meta.isTesting) {
|
||||
if (key.startsWith('account:') && value.meta && value.meta.isTesting) {
|
||||
cb && cb();
|
||||
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user