fix QR update/delete by ID
This commit is contained in:
parent
d773174bad
commit
b51bf8e38e
|
@ -854,7 +854,7 @@ export class SlashCommandHandler {
|
|||
try {
|
||||
this.api.updateQuickReply(
|
||||
args.set ?? '',
|
||||
args.label ?? '',
|
||||
args.id !== undefined ? Number(args.id) : (args.label ?? ''),
|
||||
{
|
||||
newLabel: args.newlabel,
|
||||
message: (message ?? '').trim().length > 0 ? message : undefined,
|
||||
|
@ -874,7 +874,7 @@ export class SlashCommandHandler {
|
|||
}
|
||||
deleteQuickReply(args, label) {
|
||||
try {
|
||||
this.api.deleteQuickReply(args.set, args.label ?? label);
|
||||
this.api.deleteQuickReply(args.set, args.id !== undefined ? Number(args.id) : (args.label ?? label));
|
||||
} catch (ex) {
|
||||
toastr.error(ex.message);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue