|
|
|
@ -26,7 +26,7 @@ function islandlives_pathauto_pattern_alter(PathautoPatternInterface $pattern, a |
|
|
|
// Taxonomy Terms: Only act if the pattern has machine name `person_vocabulary`. |
|
|
|
// Taxonomy Terms: Only act if the pattern has machine name `person_vocabulary`. |
|
|
|
if ($pattern->id() == 'person_vocabulary') { |
|
|
|
if ($pattern->id() == 'person_vocabulary') { |
|
|
|
// If term has no PID... |
|
|
|
// If term has no PID... |
|
|
|
$term = $context['data']['taxonomy_term']; |
|
|
|
$term = $context['data']['term']; |
|
|
|
$pid = $term->get('field_pid')->value; |
|
|
|
$pid = $term->get('field_pid')->value; |
|
|
|
if ($pid == NULL) { |
|
|
|
if ($pid == NULL) { |
|
|
|
// Replace the PID with the TID in the alias. |
|
|
|
// Replace the PID with the TID in the alias. |
|
|
|
|