Simplifying mode comparison by using array check rather than separate equality checks.
Merge pull request #24 from ameyp/simplify_command_mode_comparison

Simplifying mode comparison by using array check rather than separate eq...