extracted error handling in ImageWithErrorDummy class