Allow null args

This commit is contained in:
Magnus Ulf 2015-05-11 21:48:57 +02:00 committed by Olof Larsson
parent 345ad47ac8
commit be7c3da1b7

View File

@ -622,7 +622,10 @@ public class MassiveCommand
AR<?> reader = this.getArgReader(i);
if (ret[i] != null) continue settings; // If that index is already filled.
if ( ! reader.isValid(arg, sender)) continue settings; // If this arg isn't valid for that index.
// We do in fact want to allow null args.
// Those are used by us in some special circumstances.
if (arg != null && ! reader.isValid(arg, sender)) continue settings; // If this arg isn't valid for that index.
ret[i] = arg;
continue args; // That arg is now set :)