Fix 'removing non-existent observer'-crash.