Random transactions showing up

I’m using Moralis.Web3.getTransactions(); to get a users transaction history.

There are random transactions in the returned array that aren’t that users.
React code:

  state = {
    transactions: [],

  async componentDidMount() {
    const transactions = await Moralis.Web3.getTransactions();
    this.setState({ transactions });

You can see nonce 504134 and 0 here from addresses 0xeb2629a2734e272bcc07bda959863f316f4bd4cf and 0x9fad9ff4af0f465660cbcd8305860167a96a5a6c

Everything else is from 0x1f32d336a052237248b7a40e44dce057e8c2c8d0 (which is the current logged in user).

How do i get rid of random users transactions?

Those don’t look like random transactions, those look like transactions that some other address did to current user address, you can see the user address on the next column.

Ohh wow, you’re correct.

I jumped the gun on my hypothesis as for my purposes I only need the transactions the user made (making an ETH gas fee calculator so those can be tax deducted as a cost).

Should i just remove this post?

Great job @hexadecimal

I’ll close the topic. Don’t remove it. Let it remain for other developers who may encounter this question.

Happy BUIDLing :man_mechanic: