Elgg  Version master
AclNameHandler.php
Go to the documentation of this file.
1 <?php
2 
3 namespace Elgg\Friends;
4 
11 
19  public function __invoke(\Elgg\Event $event) {
20  $access_collection = $event->getParam('access_collection');
21  if (!$access_collection instanceof \ElggAccessCollection) {
22  return;
23  }
24 
25  if ($access_collection->getSubtype() !== 'friends') {
26  return;
27  }
28 
29  return elgg_echo('access:label:friends');
30  }
31 }
__invoke(\Elgg\Event $event)
Return the name of a friends ACL.
elgg_echo(string $message_key, array $args=[], string $language= '')
Elgg language module Functions to manage language and translations.
Definition: languages.php:17
Returns friends ACL name.
Models an event passed to event handlers.
Definition: Event.php:11