Skip to content

Commit

Permalink
fix: handle chain id being passed accidentally to evmChain
Browse files Browse the repository at this point in the history
  • Loading branch information
kelsos authored and LefterisJP committed Jun 26, 2024
1 parent 70321a9 commit fa604e6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion frontend/app/src/composables/history/events/tx/decoding.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ export const useHistoryTransactionDecoding = createSharedComposable(() => {
const type = isEvmLikeChains(chain) ? TransactionChainType.EVMLIKE : TransactionChainType.EVM;

const newPayload: ChainAndTxHash | EvmChainAndTxHash = {
...(type === TransactionChainType.EVM ? { evmChain: chain } : { chain }),
...(type === TransactionChainType.EVM ? { evmChain: transaction.evmChain } : { chain }),
txHash: transaction.txHash,
};

Expand Down
3 changes: 2 additions & 1 deletion frontend/app/src/utils/history/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { snakeCase } from 'lodash-es';
import type { EntryMeta, EntryWithMeta } from '@/types/history/meta';
import type { EvmChainAndTxHash } from '@/types/history/events';
import type { Collection } from '@/types/collection';
Expand Down Expand Up @@ -39,7 +40,7 @@ export function toEvmChainAndTxHash({
txHash?: string;
}): EvmChainAndTxHash {
return {
evmChain: location,
evmChain: snakeCase(location),
txHash: txHash || '',
};
}

0 comments on commit fa604e6

Please sign in to comment.