Cannot invoke "getKey()" because "tan element is null but I need to allow null keys - Java Community | Help. Code. Learn.