Fixed a NullPointer bug when dest key set to default