Check if the key exists before grabbing it.