summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsteveoliver2013-02-11 21:03:58 (GMT)
committer Joachim Noreiko2013-02-11 21:03:58 (GMT)
commit3fe0a348391c541d71b68c1b151866f399436d5a (patch)
tree22ebe5279f6bd2cc6714ab0d29625d376201fe92
parent4137641df0a7069f5e221c23c0c35127d621262b (diff)
Issue #1912208 by steveoliver: Fixed hook_flag_access() missing a mention of hook_flag_access_multiple().
-rw-r--r--flag.api.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/flag.api.php b/flag.api.php
index 9feb8f8..1069eb9 100644
--- a/flag.api.php
+++ b/flag.api.php
@@ -160,7 +160,10 @@ function hook_flag_validate($action, $flag, $entity_id, $account, $skip_permissi
}
/**
- * Allow modules to allow or deny access to flagging.
+ * Allow modules to allow or deny access to flagging for a single entity.
+ *
+ * Called when displaying a single entity view or edit page. For flag access
+ * checks from within Views, implement hook_flag_access_multiple().
*
* @param $flag
* The flag object.
@@ -175,6 +178,7 @@ function hook_flag_validate($action, $flag, $entity_id, $account, $skip_permissi
* Boolean TRUE if the user is allowed to flag/unflag the given entity.
* FALSE otherwise.
*
+ * @see hook_flag_access_multiple()
* @see flag_flag:access()
*/
function hook_flag_access($flag, $entity_id, $action, $account) {
@@ -182,7 +186,10 @@ function hook_flag_access($flag, $entity_id, $action, $account) {
}
/**
- * Allow modules to allow or deny access to flagging.
+ * Allow modules to allow or deny access to flagging for multiple entities.
+ *
+ * Called when preparing a View or list of multiple flaggable entities.
+ * For flag access checks for individual entities, see hook_flag_access().
*
* @param $flag
* The flag object.