Restrict command bookmarks

This commit is contained in:
Schimon Jehudah 2024-01-02 12:12:29 +00:00
parent beb5c4c976
commit 4701602355

View file

@ -275,12 +275,18 @@ async def message(self, message):
).format(muc_jid) ).format(muc_jid)
else: else:
response = ( response = (
"This response is restricted. " "This action is restricted. "
"Type: removing bookmarks." "Type: removing bookmarks."
) )
send_reply_message(self, message, response) send_reply_message(self, message, response)
case "bookmarks": case "bookmarks":
if jid == get_value("accounts", "XMPP", "operator"):
response = await compose.list_bookmarks(self) response = await compose.list_bookmarks(self)
else:
response = (
"This action is restricted. "
"Type: viewing bookmarks."
)
send_reply_message(self, message, response) send_reply_message(self, message, response)
case _ if message_lowercase.startswith("deny +"): case _ if message_lowercase.startswith("deny +"):
key = "filter-" + message_text[:4] key = "filter-" + message_text[:4]