From 1c1645096f953aa06b5809be6b302015b5bc73d6 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Thu, 29 Feb 2024 21:56:14 +0000 Subject: If a user runs an invalid command try to suggest a valid one. --- include/anope.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include') diff --git a/include/anope.h b/include/anope.h index 6031dceac..1a01db189 100644 --- a/include/anope.h +++ b/include/anope.h @@ -557,6 +557,12 @@ namespace Anope * @param len The length of the string returned */ extern CoreExport Anope::string Random(size_t len); + + /** Calculates the levenshtein distance between two strings. + * @param s1 The first string. + * @param s2 The second string. + */ + extern CoreExport size_t Distance(const Anope::string &s1, const Anope::string &s2); } /** sepstream allows for splitting token separated lists. -- cgit