add errorinfo condition