add check-types command and fix type errors

This commit is contained in:
Paul Miller
2023-07-28 11:00:00 -05:00
parent 3f8eafa93c
commit 3868b3f0a0
14 changed files with 1092 additions and 972 deletions

View File

@@ -382,9 +382,10 @@ export default function Redshift() {
return (await state.mutiny_wallet?.list_utxos()) as UtxoItem[];
};
// TODO: FIXME: this is old code needs to be revisited!
const getChannels = async () => {
console.log("Getting channels");
await state.mutiny_wallet?.sync();
// await state.mutiny_wallet?.sync();
const channels =
(await state.mutiny_wallet?.list_channels()) as Promise<
MutinyChannel[]

View File

@@ -29,9 +29,7 @@ export default function Scanner() {
let text;
if (Capacitor.isNativePlatform()) {
const { value } = await Clipboard.read({
type: "string"
});
const { value } = await Clipboard.read();
text = value;
} else {
text = await navigator.clipboard.readText();

View File

@@ -391,9 +391,7 @@ export default function Send() {
let text;
if (Capacitor.isNativePlatform()) {
const { value } = await Clipboard.read({
type: "string"
});
const { value } = await Clipboard.read();
text = value;
} else {
if (!navigator.clipboard.readText) {

View File

@@ -12,11 +12,11 @@ export default function NotFound() {
const i18n = useI18n();
return (
<SafeArea>
<Title>{i18n.t("not_found.title")}</Title>
<Title>{i18n.t("error.not_found.title")}</Title>
<HttpStatusCode code={404} />
<DefaultMain>
<LargeHeader>{i18n.t("not_found.title")}</LargeHeader>
<p>{i18n.t("not_found.wtf_paul")}</p>
<LargeHeader>{i18n.t("error.not_found.title")}</LargeHeader>
<p>{i18n.t("error.not_found.wtf_paul")}</p>
<div class="h-full" />
<ButtonLink href="/" intent="red">
{i18n.t("common.dangit")}

View File

@@ -97,9 +97,7 @@ function TwelveWordsEntry() {
let text;
if (Capacitor.isNativePlatform()) {
const { value } = await Clipboard.read({
type: "string"
});
const { value } = await Clipboard.read();
text = value;
} else {
if (!navigator.clipboard.readText) {