Skip to content

Commit

Permalink
fix(core): force interaction command to have appel, fix #1314
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed Dec 20, 2023
1 parent f5134fd commit 976ac6f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/core/src/command/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,15 @@ export class Commander extends Map<string, Command> {
const { name, options, arguments: args } = session.event.argv
session.execute({ name, args, options })
} else {
session.stripped.hasAt = true
session.stripped.appel = true
session.stripped.atSelf = true
session.stripped.prefix = ''
defineProperty(session, 'argv', ctx.bail('before-parse', session.content, session))
if (!session.argv) {
ctx.logger('command').warn('failed to parse interaction command:', session.content)
return
}
session.argv.root = true
session.argv.session = session
session.execute(session.argv)
Expand Down

0 comments on commit 976ac6f

Please sign in to comment.