Fix how switches are added to command line