handle errors when filename is not in response