fixes for input handling