code: function tryFn(fn, args) {
    try {
      return Promise.resolve(fn.apply(null, args));
    } catch (e) {
      return Promise.reject(e);
    }
  }
docs: try to resolve a function.
  resolve if it returns a resolved promise or value
  reject if it returns a rejected promise or throws an error
  @param {function} fn
  @param {array} args
  @returns {Promise}