fixed some user input bugs