|
|
@@ -3,7 +3,9 @@ import { InvalidGrowiCommandError } from '../models/errors';
|
|
|
|
|
|
export const parse = (slashCommand:{[key:string]:string}): GrowiCommand => {
|
|
|
const splitted = slashCommand.text.split(' ');
|
|
|
- if (splitted.length < 1) {
|
|
|
+ console.log('slash-command', splitted);
|
|
|
+
|
|
|
+ if (splitted[0] === '') {
|
|
|
throw new InvalidGrowiCommandError('The SlashCommand.text does not specify GrowiCommand type');
|
|
|
}
|
|
|
|