Fixed layer of logic in sendCommand.