From 19f1f93cfacd94b510d1f067cdb3d4de78b5b9c7 Mon Sep 17 00:00:00 2001 From: lub Date: Sat, 14 Oct 2017 21:48:24 +0200 Subject: [PATCH] rename bang to project --- index.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/index.js b/index.js index 9422887..b1774b8 100644 --- a/index.js +++ b/index.js @@ -80,14 +80,14 @@ matrixclient.on('Room.timeline', function(event, room, resettimeline) { let body = event.getContent().body; - let bang = body.match(/^\!([a-zA-Z]*)/); - if(bang === null) { + let project = body.match(/^\!([a-zA-Z]*)/); + if(project === null) { return; } - bang = bang[1]; + project = project[1]; - if(commands[bang] !== undefined) { - let command = commands[bang]; + if(commands[project] !== undefined) { + let command = commands[project]; let args = body.match(command['regex']); if(args === null) {