This logic does not work becaause if the `len(key) > 1` it is trying to find a key button with a long string in it.