bugfix of buildCmdCond