/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/app/View/Composers/Archive.php
'name' => $all_categories,
'slug' => '*',
'icon' => 'all-press',
'link' => get_permalink( get_option('page_for_posts') ),
'current' => (is_home())? true : false,
)
);
if($terms){
foreach($terms as $term){
$context['press_types'][] = array(
'name' => $term->name,
'slug' => $term->slug,
'icon' => $term->slug,
'link' => get_term_link($term),
'current' => (is_tax('press-type', $term->term_id))? true : false,
);
}
}
$context['pagination'] = Timber::get_pagination();
//if($terms){
// foreach($terms as $term){
// $context['press_types'][] = new TimberTerm($term->term_id, 'press-type');
// }
//}
//Timber::render('templates/taxonomy-press-type.twig', $context);
return $context;
}else {
$context['is_press_type'] = false;
print_r('unsupported');
die();
}
return [
'title' => $this->title(),
];
}
Arguments
"Class 'App\View\Composers\Timber' not found"
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/roots/acorn/src/Acorn/View/Composer.php
*/
public function compose(View $view)
{
$this->view = $view;
$this->data = new Fluent($view->getData());
$view->with($this->merge());
}
/**
* Data to be merged and passed to the view before rendering.
*
* @return array
*/
protected function merge()
{
return array_merge(
$this->with(),
$this->view->getData(),
$this->override()
);
}
/**
* Data to be passed to view before rendering
*
* @return array
*/
protected function with()
{
return [];
}
/**
* Data to be passed to view before rendering
*
* @return array
*/
protected function override()
{
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/roots/acorn/src/Acorn/View/Composer.php
return static::$views;
}
$view = array_slice(explode('\\', static::class), 3);
$view = array_map([Str::class, 'snake'], $view, array_fill(0, count($view), '-'));
return implode('/', $view);
}
/**
* Compose the view before rendering.
*
* @param \Illuminate\View\View $view
* @return void
*/
public function compose(View $view)
{
$this->view = $view;
$this->data = new Fluent($view->getData());
$view->with($this->merge());
}
/**
* Data to be merged and passed to the view before rendering.
*
* @return array
*/
protected function merge()
{
return array_merge(
$this->with(),
$this->view->getData(),
$this->override()
);
}
/**
* Data to be passed to view before rendering
*
* @return array
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/view/Concerns/ManagesEvents.php
return $callback;
}
/**
* Build a class based container callback Closure.
*
* @param string $class
* @param string $prefix
* @return \Closure
*/
protected function buildClassEventCallback($class, $prefix)
{
[$class, $method] = $this->parseClassEvent($class, $prefix);
// Once we have the class and method name, we can build the Closure to resolve
// the instance out of the IoC container and call the method on it with the
// given arguments that are passed to the Closure as the composer's data.
return function () use ($class, $method) {
return $this->container->make($class)->{$method}(...func_get_args());
};
}
/**
* Parse a class based composer name.
*
* @param string $class
* @param string $prefix
* @return array
*/
protected function parseClassEvent($class, $prefix)
{
return Str::parseCallback($class, $this->classEventMethodForPrefix($prefix));
}
/**
* Determine the class event method based on the given prefix.
*
* @param string $prefix
* @return string
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/events/Dispatcher.php
* @param \Closure|string $listener
* @param bool $wildcard
* @return \Closure
*/
public function makeListener($listener, $wildcard = false)
{
if (is_string($listener)) {
return $this->createClassListener($listener, $wildcard);
}
if (is_array($listener) && isset($listener[0]) && is_string($listener[0])) {
return $this->createClassListener($listener, $wildcard);
}
return function ($event, $payload) use ($listener, $wildcard) {
if ($wildcard) {
return $listener($event, $payload);
}
return $listener(...array_values($payload));
};
}
/**
* Create a class based listener using the IoC container.
*
* @param string $listener
* @param bool $wildcard
* @return \Closure
*/
public function createClassListener($listener, $wildcard = false)
{
return function ($event, $payload) use ($listener, $wildcard) {
if ($wildcard) {
return call_user_func($this->createClassCallable($listener), $event, $payload);
}
$callable = $this->createClassCallable($listener);
return $callable(...array_values($payload));
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/events/Dispatcher.php
* @param bool $halt
* @return array|null
*/
public function dispatch($event, $payload = [], $halt = false)
{
// When the given "event" is actually an object we will assume it is an event
// object and use the class as the event name and this event itself as the
// payload to the handler, which makes object based events quite simple.
[$event, $payload] = $this->parseEventAndPayload(
$event, $payload
);
if ($this->shouldBroadcast($payload)) {
$this->broadcastEvent($payload[0]);
}
$responses = [];
foreach ($this->getListeners($event) as $listener) {
$response = $listener($event, $payload);
// If a response is returned from the listener and event halting is enabled
// we will just return this response, and not call the rest of the event
// listeners. Otherwise we will add the response on the response list.
if ($halt && ! is_null($response)) {
return $response;
}
// If a boolean false is returned from a listener, we will stop propagating
// the event to any further listeners down in the chain, else we keep on
// looping through the listeners and firing every one in our sequence.
if ($response === false) {
break;
}
$responses[] = $response;
}
return $halt ? null : $responses;
}
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/view/Concerns/ManagesEvents.php
protected function addEventListener($name, $callback)
{
if (Str::contains($name, '*')) {
$callback = function ($name, array $data) use ($callback) {
return $callback($data[0]);
};
}
$this->events->listen($name, $callback);
}
/**
* Call the composer for a given view.
*
* @param \Illuminate\Contracts\View\View $view
* @return void
*/
public function callComposer(ViewContract $view)
{
$this->events->dispatch('composing: '.$view->name(), [$view]);
}
/**
* Call the creator for a given view.
*
* @param \Illuminate\Contracts\View\View $view
* @return void
*/
public function callCreator(ViewContract $view)
{
$this->events->dispatch('creating: '.$view->name(), [$view]);
}
}
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/view/View.php
} catch (Throwable $e) {
$this->factory->flushState();
throw $e;
}
}
/**
* Get the contents of the view instance.
*
* @return string
*/
protected function renderContents()
{
// We will keep track of the amount of views being rendered so we can flush
// the section after the complete rendering operation is done. This will
// clear out the sections for any separate views that may be rendered.
$this->factory->incrementRender();
$this->factory->callComposer($this);
$contents = $this->getContents();
// Once we've finished rendering the view, we'll decrement the render count
// so that each sections get flushed out next time a view is created and
// no old sections are staying around in the memory of an environment.
$this->factory->decrementRender();
return $contents;
}
/**
* Get the evaluated contents of the view.
*
* @return string
*/
protected function getContents()
{
return $this->engine->get($this->path, $this->gatherData());
}
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/vendor/illuminate/view/View.php
$this->view = $view;
$this->path = $path;
$this->engine = $engine;
$this->factory = $factory;
$this->data = $data instanceof Arrayable ? $data->toArray() : (array) $data;
}
/**
* Get the string contents of the view.
*
* @param callable|null $callback
* @return array|string
*
* @throws \Throwable
*/
public function render(callable $callback = null)
{
try {
$contents = $this->renderContents();
$response = isset($callback) ? $callback($this, $contents) : null;
// Once we have the contents of the view, we will flush the sections if we are
// done rendering all views so that there is nothing left hanging over when
// another view gets rendered in the future by the application developer.
$this->factory->flushStateIfDoneRendering();
return ! is_null($response) ? $response : $contents;
} catch (Throwable $e) {
$this->factory->flushState();
throw $e;
}
}
/**
* Get the contents of the view instance.
*
* @return string
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/index.php
<!doctype html>
<?php echo \Roots\view(\Roots\app('sage.view'), \Roots\app('sage.data'))->render(); ?>
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/wp/wp-includes/template-loader.php
}
break;
}
}
if ( ! $template ) {
$template = get_index_template();
}
/**
* Filters the path of the current template before including it.
*
* @since 3.0.0
*
* @param string $template The path of the template to include.
*/
$template = apply_filters( 'template_include', $template );
if ( $template ) {
include $template;
} elseif ( current_user_can( 'switch_themes' ) ) {
$theme = wp_get_theme();
if ( $theme->errors() ) {
wp_die( $theme->errors() );
}
}
return;
}
Arguments
"/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/app/themes/nevro/index.php"
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/wp/wp-blog-header.php
<?php
/**
* Loads the WordPress environment and template.
*
* @package WordPress
*/
if ( ! isset( $wp_did_header ) ) {
$wp_did_header = true;
// Load the WordPress library.
require_once __DIR__ . '/wp-load.php';
// Set up the WordPress query.
wp();
// Load the theme template.
require_once ABSPATH . WPINC . '/template-loader.php';
}
Arguments
"/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/wp/wp-includes/template-loader.php"
/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/index.php
<?php
/**
* WordPress View Bootstrapper
*/
define('WP_USE_THEMES', true);
require __DIR__ . '/wp/wp-blog-header.php';
Arguments
"/home/forge/uat.hf10-pdn.staging.poundandgrain.ca/releases/20221213172529/web/wp/wp-blog-header.php"