BF: Made /op work when providing no power value. 50 is used as default in this case

pull/10/head
Emmanuel ROHEE 2014-09-10 17:37:51 +02:00
parent 811716592c
commit 81ecaf945d
1 changed files with 1 additions and 1 deletions

View File

@ -460,7 +460,7 @@ angular.module('RoomController', ['ngSanitize', 'matrixFilter', 'mFileInput'])
var powerLevel = 50; // default power level for op
if (matches) {
var user_id = matches[1];
if (matches.length === 4) {
if (matches.length === 4 && undefined !== matches[3]) {
powerLevel = parseInt(matches[3]);
}
if (powerLevel !== NaN) {