Minor documentation change as well as parameter check.
This commit is contained in:
parent
efd81fe00f
commit
951476a2e6
@ -82,9 +82,10 @@ namespace RecrownedGTK.Tools.CommandProcessor
|
|||||||
/// Check if the command exists using it's invokes string.
|
/// Check if the command exists using it's invokes string.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="command">A string that will invoke the command.</param>
|
/// <param name="command">A string that will invoke the command.</param>
|
||||||
/// <returns></returns>
|
/// <returns>Returns true if the given invoke string exists as a command and false if command parameter is null.</returns>
|
||||||
public bool ContainsCommand(string command)
|
public bool ContainsCommand(string command)
|
||||||
{
|
{
|
||||||
|
if (command == null) return false;
|
||||||
for (int i = 0; i < commands.Count; i++)
|
for (int i = 0; i < commands.Count; i++)
|
||||||
{
|
{
|
||||||
if (commands[i].IsInvoked(command)) return true;
|
if (commands[i].IsInvoked(command)) return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user