add processing error check