# All files / node-request-retry/strategies HTTPOrNetworkError.js

100% Statements 3/3
100% Branches 2/2
100% Functions 2/2
100% Lines 3/3

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    1x

    1x
    59x

     'use strict';
    module.exports = function HTTPOrNetworkError(httpError, networkError) {
      /**
       * @param  {Null | Object} err
       * @param  {Object} response
       * @return {Boolean} true if the request had a recoverable HTTP or network error
       */
      return function HTTPError(err, response) {
        return httpError(err, response) || networkError(err, response);
      };

    };