halt method

Future<void> halt()

Halts the conversation immediately.

This terminates the conversation and cleans up any stored state.

Example:

if (ctx.text == 'cancel') {
  await ctx.reply('Conversation cancelled.');
  await conversation.halt();
}

Implementation

Future<void> halt() async {
  await _plugin.forceCleanupConversation(_storageKey);
}