bug fix in getKeyboardResponse