You are here

public function StringTransformTrait::deleteWildcards in Drupal 7 to 8/9 Module Upgrader 8

Deletes {wildcards} from a route path.

Parameters

string $path:

Return value

string

1 call to StringTransformTrait::deleteWildcards()
StringTransformTrait::getIdentifierFromPath in src/Utility/StringTransformTrait.php
Generates an identifier from a path.

File

src/Utility/StringTransformTrait.php, line 75

Class

StringTransformTrait
Contains methods for transforming strings in various helpful ways.

Namespace

Drupal\drupalmoduleupgrader\Utility

Code

public function deleteWildcards($path) {
  return preg_replace('/\\/?\\{([a-zA-Z0-9_]+)\\}/', NULL, $path);
}