aboutsummaryrefslogtreecommitdiff
path: root/CmdLine.hs
diff options
context:
space:
mode:
Diffstat (limited to 'CmdLine.hs')
-rw-r--r--CmdLine.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/CmdLine.hs b/CmdLine.hs
index 6ac0b423f..68157a01a 100644
--- a/CmdLine.hs
+++ b/CmdLine.hs
@@ -47,7 +47,7 @@ dispatch args cmds commonoptions header getgitrepo = do
- the Command being run, and the remaining parameters for the command. -}
parseCmd :: Params -> [Command] -> [Option] -> String -> (Flags, Command, Params)
parseCmd argv cmds commonoptions header
- | name == Nothing = err "missing command"
+ | isNothing name = err "missing command"
| null matches = err $ "unknown command " ++ fromJust name
| otherwise = check $ getOpt Permute (commonoptions ++ cmdoptions cmd) args
where