fix the key error