Skip to content

Commit

Permalink
chore(app): fixed fmt errors
Browse files Browse the repository at this point in the history
Signed-off-by: Kaan Caglan <[email protected]>
  • Loading branch information
Caglankaan committed Mar 6, 2025
1 parent 3f9af8a commit 845f77d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ const transfer = async () => {
if (!rpcUrl) return toast.error(`no rpc available for ${sourceChain.display_name}`)
if (!rpcUrl.endsWith("/v1", rpcUrl.length - 3)) {
rpcUrl = rpcUrl + "/v1"
rpcUrl = `${rpcUrl}/v1`
}
rpcUrl = "https://aptos.testnet.bardock.movementlabs.xyz/v1" //TODO: Remove this later its for test
Expand Down
2 changes: 1 addition & 1 deletion app/src/lib/components/TransferCube/index.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ onMount(() => {
const unsubscribe = transfer.subscribe(trans => {
const chain = trans.intents.sourceChain
if (chain) {
let userAddr
let userAddr: string | undefined
if (chain.rpc_type === "evm") {
userAddr = $userAddress.evm?.canonical.toLowerCase()
} else if (chain.rpc_type === "aptos" || chain.chain_id === "movement") {
Expand Down
4 changes: 2 additions & 2 deletions app/src/lib/stores/balances.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ export async function updateBalancesAptos(chain: Chain, address: Address) {
throw new Error(response.error.message)
}
const data = response.value.data
if (!data || !data.current_fungible_asset_balances) {
if (!data?.current_fungible_asset_balances) {
throw new Error("Invalid response data")
}

Expand All @@ -133,7 +133,7 @@ export async function updateBalancesAptos(chain: Chain, address: Address) {
} catch (error: any) {
console.error("Error fetching Aptos balances", error)
// On error, update the balances for all tokens with an error state.
if (chain.tokens?.length) {
if (chain.tokens?.length > 0) {
chain.tokens.forEach(token =>
updateBalance(chain.chain_id, token.denom, {
kind: "error",
Expand Down

0 comments on commit 845f77d

Please sign in to comment.