private function execute($callback, array $which, array $args = [])
    {
        if (! is_string($callback)) {
            throw new InvalidArgumentException('Foil callback name must be in a string.');
        }
        if (array_key_exists($callback, $which)) {
            return call_user_func_array($which[$callback], $args);
        }
        throw new LogicException('"'.$callback.'" is not a registered Foil callback.');
    }
private function execute($callback, array $which, array $args = [])
    {
        if (! is_string($callback)) {
            throw new InvalidArgumentException('Foil callback name must be in a string.');
        }
        if (array_key_exists($callback, $which)) {
            return call_user_func_array($which[$callback], $args);
        }
        throw new LogicException('"'.$callback.'" is not a registered Foil callback.');
    }
private function execute ( $ callback , array $ which , array $ args = [ ] ) { if ( ! is_string ( $ callback ) ) { throw new InvalidArgumentException ( 'Foil callback name must be in a string.' ) ; } if ( array_key_exists ( $ callback , $ which ) ) { return call_user_func_array ( $ which [ $ callback ] , $ args ) ; } throw new LogicException ( '"' . $ callback . '" is not a registered Foil callback.' ) ; }
Run a registered callback

@param  string                   $callback
@param  array                    $which    functions or filters
@param  array                    $args     execution arguments
@return mixed
@throws InvalidArgumentException If callback is not a valid registered callback name
Run a registered callback