Fix command.replace