This commit is contained in:
Luke Barnard 2017-06-23 17:35:07 +01:00
parent 004d4828f8
commit 89afcfd897
7 changed files with 23 additions and 17 deletions

View file

@ -77,7 +77,7 @@ const COMMANDS = [
command: '/op',
args: '<userId> [<power level>]',
description: 'Define the power level of a user',
}
},
];
const COMMAND_RE = /(^\/\w*)/g;
@ -96,7 +96,7 @@ export default class CommandProvider extends AutocompleteProvider {
let completions = [];
const {command, range} = this.getCurrentCommand(query, selection);
if (command) {
completions = this.matcher.match(command[0]).map(result => {
completions = this.matcher.match(command[0]).map((result) => {
return {
completion: result.command + ' ',
component: (<TextualCompletion