adding in self.ERROR to keep an overall value of build status. Added catch for mail process call