/[sudobot]/trunk/src/commands/automation/ExpireScheduleCommand.ts
ViewVC logotype

Diff of /trunk/src/commands/automation/ExpireScheduleCommand.ts

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 51 by rakin, Mon Jul 29 17:28:23 2024 UTC revision 72 by rakin, Mon Jul 29 17:28:29 2024 UTC
# Line 4  import DiscordClient from '../../client/ Line 4  import DiscordClient from '../../client/
4  import CommandOptions from '../../types/CommandOptions';  import CommandOptions from '../../types/CommandOptions';
5  import InteractionOptions from '../../types/InteractionOptions';  import InteractionOptions from '../../types/InteractionOptions';
6  import MessageEmbed from '../../client/MessageEmbed';  import MessageEmbed from '../../client/MessageEmbed';
 import Help from '../../utils/help';  
7  import ms from 'ms';  import ms from 'ms';
8  import { timeSince } from '../../utils/util';  import { timeSince } from '../../utils/util';
9  import { setTimeoutv2 } from '../../utils/setTimeout';  import { setTimeoutv2 } from '../../utils/setTimeout';
# Line 79  export default class ExpireScheduleComma Line 78  export default class ExpireScheduleComma
78              text = args.join(' ');              text = args.join(' ');
79          }          }
80    
81            if (!channel.send) {
82                await msg.reply({
83                    content: 'Invalid text channel.',
84                    ephemeral: true
85                });
86    
87                return;
88            }
89    
90          try {          try {
91              const timeout = await setTimeoutv2('send-expire.ts', time1, msg.guild!.id, `expiresc ${time1} ${time2} ${text!} #${channel.name}`, text!, channel.id, msg.guild!.id, time2);              const timeout = await setTimeoutv2('send-expire', time1, msg.guild!.id, `expiresc ${time1} ${time2} ${text!} #${channel.name}`, text!, channel.id, msg.guild!.id, time2);
92    
93              await msg.reply({              await msg.reply({
94                  embeds: [                  embeds: [

Legend:
Removed from v.51  
changed lines
  Added in v.72

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26