Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. TwigFunction.php

function TwigFunction::getSafe

File

vendor/twig/twig/src/TwigFunction.php, line 51

Class

TwigFunction
Represents a template function.

Namespace

Twig

Code

public function getSafe(Node $functionArgs) : ?array {
    if (null !== $this->options['is_safe']) {
        return $this->options['is_safe'];
    }
    if (null !== $this->options['is_safe_callback']) {
        return $this->options['is_safe_callback']($functionArgs);
    }
    return [];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal