Bump deps, update tests (#728)

* Bump deps, update tests

* Update stale.yml

* void handlers
This commit is contained in:
Jaco
2021-05-29 10:34:51 +02:00
committed by GitHub
parent 3ed90ae23a
commit fb7dfb3ddc
18 changed files with 1127 additions and 1203 deletions
@@ -3,12 +3,12 @@
import '../../../../../__mocks__/chrome';
import type { ResponseSigning } from '@polkadot/extension-base/background/types';
import type { MetadataDef } from '@polkadot/extension-inject/types';
import type { KeyringPair } from '@polkadot/keyring/types';
import type { ExtDef } from '@polkadot/types/extrinsic/signedExtensions/types';
import type { SignerPayloadJSON } from '@polkadot/types/types';
import { ResponseSigning } from '@polkadot/extension-base/background/types';
import { MetadataDef } from '@polkadot/extension-inject/types';
import { KeyringPair } from '@polkadot/keyring/types';
import { TypeRegistry } from '@polkadot/types';
import keyring from '@polkadot/ui-keyring';
import { cryptoWaitReady } from '@polkadot/util-crypto';
@@ -450,7 +450,9 @@ export default class Extension {
}
console.log('open', url);
chrome.tabs.create({ url });
// eslint-disable-next-line no-void
void chrome.tabs.create({ url });
return true;
}
@@ -155,7 +155,8 @@ export default class State {
private popupClose (): void {
this.#windows.forEach((id: number): void =>
chrome.windows.remove(id)
// eslint-disable-next-line no-void
void chrome.windows.remove(id)
);
this.#windows = [];
}
@@ -258,7 +259,8 @@ export default class State {
: (signCount ? `${signCount}` : '')
);
chrome.browserAction.setBadgeText({ text });
// eslint-disable-next-line no-void
void chrome.browserAction.setBadgeText({ text });
if (shouldClose && text === '') {
this.popupClose();
@@ -149,7 +149,10 @@ export default class Tabs {
tabs
.map(({ id }) => id)
.filter((id): id is number => isNumber(id))
.forEach((id) => chrome.tabs.update(id, { url }));
.forEach((id) =>
// eslint-disable-next-line no-void
void chrome.tabs.update(id, { url })
);
});
}