Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
eduardozgz committed Jan 27, 2023
2 parents 39ab1b5 + cae412a commit 68326f0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/utils/commandHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,9 @@ export default async (message: Eris.Message) => {

const commandRequested = content.toLowerCase(); // Case insensitive match
const matchedPrefix = commandRequested.match(prefixRegex)?.[0];
if (matchedPrefix == null) return;
if (!commandRequested.startsWith(matchedPrefix)) return;

if (!matchedPrefix) return;

const commandRequestedWithoutPrefix = commandRequested
.replace(matchedPrefix, "")
.trim();
Expand Down

0 comments on commit 68326f0

Please sign in to comment.