function checkError(resp) {
    var value = this.config.successValue;
    if (typeof value === 'number') {
      return resp.httpResponse.statusCode === value;
    } else {
      return resp.error && resp.error.code === value;
    }
  }
function checkError(resp) {
    var value = this.config.successValue;
    if (typeof value === 'number') {
      return resp.httpResponse.statusCode === value;
    } else {
      return resp.error && resp.error.code === value;
    }
  }
function checkError ( resp ) { var value = this . config . successValue ; if ( typeof value === 'number' ) { return resp . httpResponse . statusCode === value ; } else { return resp . error && resp . error . code === value ; } }
Checks if the terminal expected error state has been met
@return [Boolean]
Checks if the terminal expected error state has been met