mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-20 18:16:21 +00:00
Add clear_device_list command
This commit is contained in:
@@ -87,6 +87,7 @@
|
||||
|
||||
#ifdef HAVE_OMEMO
|
||||
#include "omemo/omemo.h"
|
||||
#include "xmpp/omemo.h"
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_GTK
|
||||
@@ -8268,3 +8269,21 @@ cmd_omemo_untrust(ProfWin *window, const char *const command, gchar **args)
|
||||
return TRUE;
|
||||
#endif
|
||||
}
|
||||
|
||||
gboolean
|
||||
cmd_omemo_clear_device_list(ProfWin *window, const char *const command, gchar **args)
|
||||
{
|
||||
#ifdef HAVE_OMEMO
|
||||
if (connection_get_status() != JABBER_CONNECTED) {
|
||||
cons_show("You must be connected with an account to initialize OMEMO.");
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
omemo_devicelist_publish(NULL);
|
||||
cons_show("Cleared OMEMO device list");
|
||||
return TRUE;
|
||||
#else
|
||||
cons_show("This version of Profanity has not been built with OMEMO support enabled");
|
||||
return TRUE;
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user