ownerChangedEvent

Creates an event object for the OwnerChanged event.

Example

import { getContractEvents } from "thirdweb";
import { ownerChangedEvent } from "thirdweb/extensions/uniswap";
const events = await getContractEvents({
contract,
events: [
ownerChangedEvent({
oldOwner: ...,
newOwner: ...,
})
],
});
function ownerChangedEvent(
filters: Partial<{ newOwner: string; oldOwner: string }>,
readonly inputs: readonly [
{
readonly indexed: true;
readonly name: "oldOwner";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "newOwner";
readonly type: "address";
},
];
readonly name: "OwnerChanged";
readonly type: "event";
}>;

Parameters

Optional filters to apply to the event.

Type

let filters: Partial<{ newOwner: string; oldOwner: string }>;

Returns

let returnType: PreparedEvent<{
readonly inputs: readonly [
{
readonly indexed: true;
readonly name: "oldOwner";
readonly type: "address";
},
{
readonly indexed: true;
readonly name: "newOwner";
readonly type: "address";
},
];
readonly name: "OwnerChanged";
readonly type: "event";
}>;

The prepared event object.