.savechat will now be unlimited if ran by the bot owner

This commit is contained in:
Toastie 2025-03-15 11:44:18 +13:00
parent e77f85edc6
commit fbb9064434
Signed by: toastie_t0ast
GPG key ID: 0861BE54AD481DC7
2 changed files with 85 additions and 79 deletions
src/EllieBot
Modules/Utility
strings/commands

View file

@ -649,7 +649,7 @@ public partial class Utility : EllieModule
[Ratelimit(3600)]
public async Task SaveChat(int cnt)
{
if (cnt > 1000)
if (!_creds.IsOwner(ctx.User) && cnt > 1000)
return;
var msgs = new List<IMessage>(cnt);

View file

@ -378,8 +378,8 @@ sargroupdelete:
desc: "The number of the group to delete."
sarexclusive:
desc: |-
Toggles whether self-assigned roles are exclusive.
While enabled, users can only have one self-assignable role per group.
Toggles the sar group as exclusive.
While enabled, users can only have one self-assignable role from that group.
ex:
- '1'
params:
@ -418,7 +418,11 @@ iamnot:
- role:
desc: "The role to remove."
expradd:
desc: 'Add an expression with a trigger and a response. Bot will post a response whenever someone types the trigger word. Running this command in a server requires the Administrator permission. Running this command in DM is Bot Owner only and adds a new global expression. Guide [here](<https://docs.elliebot.net/ellie/features/expressions/>)'
desc: |-
Add an expression with a trigger and a response.
Bot will post a response whenever someone types the trigger word.
Running this command in a server requires the Administrator permission.
Running this command in DM is Bot Owner only and adds a new global expression.
ex:
- '"hello" Hi there %user.mention%'
params:
@ -427,7 +431,7 @@ expradd:
response:
desc: "The text of the message that shows up when a user types the trigger word or phrase."
expraddserver:
desc: 'Add an expression with a trigger and a response in this server. Bot will post a response whenever someone types the trigger word. This command is useful if you want to lower the permission requirement for managing expressions by using `{0}dpo`. Guide [here](<https://docs.elliebot.net/ellie/features/expressions/>).'
desc: 'Add an expression with a trigger and a response in this server. Bot will post a response whenever someone types the trigger word. This command is useful if you want to lower the permission requirement for managing expressions by using `{0}dpo`.'
ex:
- '"hello" Hi there %user.mention%'
params:
@ -892,7 +896,9 @@ send:
text:
desc: "The recipient's preferred format for the message, such as plain text or formatted text with images and links."
savechat:
desc: Saves a number of messages to a text file and sends it to you.
desc: |-
Saves a number of messages to a text file and sends it to you.
Max is 1000, unless you're the bot owner.
ex:
- 150
params: