standby test and fix some bugs

i cannot see why this is correct. 
it seems that we should make this to nil and when restart we can make another map.