Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
<?php
if ($flag->hasActionAccess('flag ' . $flag->id(), $account) || $flag->hasActionAccess('unflag ' . $flag->id(), $account)) {
?>
But hasActionAccess() clearly only expects either 'flag' or 'unflag' for the access param.
Comment | File | Size | Author |
---|---|---|---|
#2 | flag-2416517-2.patch | 523 bytes | joshi.rohit100 |
Comments
Comment #1
lokapujyaYes, I think $flag already knows its own id, so I think we just remove the appended id.
Comment #2
joshi.rohit100removed the flag-id added in hasActionAccess() method.
Comment #4
socketwench CreditAttribution: socketwench commentedThanks!