function boolOrFn(val, args) {
  if ((typeof val === 'undefined' ? 'undefined' : _typeof(val)) === TYPE_FUNCTION) {
    return val.apply(args ? args[0] || undefined : undefined, args);
  }
  return val;
}
@private
let a boolean value also be a function that must return a boolean
this first item in args will be used as the context
@param {Boolean|Function} val
@param {Array} [args]
@returns {Boolean}