src/View/SSViewer_DataPresenter.php
protected function processTemplateOverride($property, $overrides)
    {
        if (!isset($overrides[$property])) {
            return null;
        }

        // Detect override type
        $override = $overrides[$property];

        // Late-evaluate this value
        if (!is_string($override) && is_callable($override)) {
            $override = $override();

            // Late override may yet return null
            if (!isset($override)) {
                return null;
            }
        }

        return [ 'value' => $override ];
    }
protected function processTemplateOverride($property, $overrides)
    {
        if (!isset($overrides[$property])) {
            return null;
        }

        // Detect override type
        $override = $overrides[$property];

        // Late-evaluate this value
        if (!is_string($override) && is_callable($override)) {
            $override = $override();

            // Late override may yet return null
            if (!isset($override)) {
                return null;
            }
        }

        return [ 'value' => $override ];
    }
protected function processTemplateOverride ( $ property , $ overrides ) { if ( ! isset ( $ overrides [ $ property ] ) ) { return null ; } // Detect override type $ override = $ overrides [ $ property ] ; // Late-evaluate this value if ( ! is_string ( $ override ) && is_callable ( $ override ) ) { $ override = $ override ( ) ; // Late override may yet return null if ( ! isset ( $ override ) ) { return null ; } } return [ 'value' => $ override ] ; }
Evaluate a template override

@param string $property Name of override requested
@param array $overrides List of overrides available
@return null|array Null if not provided, or array with 'value' or 'callable' key
Evaluate a template override