Closed (fixed)
Project:
Pathauto
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
22 Mar 2016 at 14:05 UTC
Updated:
22 Sep 2018 at 11:39 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
lpsolit commentedComment #3
berdirDo we even invoke the hook at the moment? There's another issue about hooks not being invoked..
Comment #4
feyp commentedThanks for your patch. I'll set it back to needs work. The updated example looks good at a first glance (didn't test it), but while you're at it, the DocBlock of the hook should also be updated. E.g. the
$patternparameter is no longer astring, but a\Drupal\pathauto\PathautoPatternInterfaceand there might as well be changes in the context variable.> Do we even invoke the hook at the moment? There's another issue about hooks not being invoked..
It has been a few days, so it might have been fixed in the meantime. From looking at the source code, the hook is indeed invoked in
\Drupal\pathauto\PathautoGenerator::createEntityAlias(), although there is a// @todo Is still hook still useful?directly above it.Comment #5
spurlos commentedI have updated the patch to mention
PathautoPatternInterfaceusage.Comment #6
gaurav.kapoor commentedComment #7
dinesh18 commentedThe Pathauto pattern entity which need its patter to be modified using.spelling mistake written patter instead of pattern
Comment #8
dinesh18 commentedHere is the updated patch and interdiff.txt
Comment #9
gettysburger commentedComment #3 says "Do we even invoke the hook at the moment? There's another issue about hooks not being invoked.."
Is there a link to this issue? Tanks.
Comment #10
madhavvyas commented#8 patch looks good to me.
Comment #11
luke.leberOn patch #8, if I'm not mistaken the type specifier in the @param annotation is generally the fully qualified class name with namespace.
Comment #12
idebr commentedUpdated to the fully qualified namespace to match Drupal coding standards.
*.api.php files use fully qualified namespace arguments, see for example http://cgit.drupalcode.org/drupal/tree/core/modules/media/media.api.php
Comment #14
berdirComment #16
berdirComment #18
berdirThanks, committed.
PS: issue credit these days is mostly about the issue metadata not the commit message. Just list the users to be added additionally, then I can add them .