Some issues due to version upgrade of Moralis and react-moralis libraries

Hello, everyone.
I have some issues due to version upgrade of Moralis(0.0.118 to 1.3.2) and react-moralis(0.2.8 to 1.3.1) libraries.

For example:

const tx = await Moralis.executeFunction({ awaitReceipt: false, …options });
tx.on(“transactionHash”, (hash) => {
openNotification({
message: “:loud_sound: New Transaction”,
description: 📃 Tx Hash: ${hash},
type: “success”
});
})
.on(“receipt”, (receipt) => {
openNotification({
message: “:loud_sound: New Receipt”,
description: 📃 Receipt: ${receipt.transactionHash},
type: “success”
});
})
.on(“error”, (error) => {
openNotification({
message: “:loud_sound: Error”,
description: 📃 Receipt: ${error.toString()},
type: “error”
});
console.log(error);
});

In this code, there comes an error that tx.on is not a function.

If you can fix them, please help me.

Thank you for paying attention to this post.