fix a bug when errors happens without response