SentNostrEvent.deleteEvent constructor
SentNostrEvent.deleteEvent({
- required NostrKeyPairs keyPairs,
- required List<
String> eventIdsToBeDeleted, - String reasonOfDeletion = "",
- DateTime? createdAt,
Implementation
factory SentNostrEvent.deleteEvent({
required NostrKeyPairs keyPairs,
required List<String> eventIdsToBeDeleted,
String reasonOfDeletion = "",
DateTime? createdAt,
}) {
assert(
eventIdsToBeDeleted.isNotEmpty,
"the list of event ids is empty, "
"you must provide at least one event id to be deleted.",
);
return SentNostrEvent.fromPartialData(
kind: 5,
content: reasonOfDeletion,
keyPairs: keyPairs,
tags: eventIdsToBeDeleted.map((eventId) => ["e", eventId]).toList(),
createdAt: createdAt,
);
}