You are here

public static function FieldRedirectionResult::deny in Field Redirection 8.2

Factory method for a field redirection result that should not redirect.

Return value

\Drupal\field_redirection\FieldRedirectionResult New instance.

4 calls to FieldRedirectionResult::deny()
FieldRedirectionResultBuilder::buildResult in src/FieldRedirectionResultBuilder.php
Builds a redirection result for a given set of values.
FieldRedirectionResultBuilderLinkTest::testFieldRedirectionResultBuilderDenyStates in tests/src/Kernel/FieldRedirectionResultBuilderLinkTest.php
Tests builder.
FieldRedirectionResultBuilderLinkTest::testFieldRedirectionResultMaintenanceMode in tests/src/Kernel/FieldRedirectionResultBuilderLinkTest.php
Tests the maintenance mode.
FieldRedirectionResultUnitTest::testDeny in tests/src/Unit/FieldRedirectionResultUnitTest.php
@covers ::deny

File

src/FieldRedirectionResult.php, line 84

Class

FieldRedirectionResult
Defines a value object for a field redirection result.

Namespace

Drupal\field_redirection

Code

public static function deny() {
  $instance = new static();
  $instance->shouldRedirect = FALSE;
  return $instance;
}