Added configurable error checks instead of stupid /^ERROR/ check.