Return correct error in InspectImage