Fix issue in error count