code: function maybeCallback(fn) {
      return function maybeContinuable() {
          var args = slice.call(arguments)
          var callback = args[args.length - 1]
  
          if (typeof callback === "function") {
              args.pop()
          }
  
          var continuable = fn.apply(null, args)
  
          if (typeof callback === "function") {
              continuable(callback)
          } else {
              return continuable
          }
      }
  }
docs: maybeCallback := (fn: (Any, ...) => Continuable<T>) => (Any, ..., Callback<T>?) => Continuable<T>