Fixes a bug that would cause the first keyboard input to be ignored.