? trigger_hook_access-324183-6.patch
? sites/default/files
? sites/default/settings.php
Index: modules/trigger/trigger.api.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/trigger/trigger.api.php,v
retrieving revision 1.3
diff -u -p -r1.3 trigger.api.php
--- modules/trigger/trigger.api.php	8 Mar 2009 04:25:07 -0000	1.3
+++ modules/trigger/trigger.api.php	1 May 2009 06:02:30 -0000
@@ -120,6 +120,11 @@ function hook_action_info_alter(&$action
  *       - Inside of that array are a list of arrays keyed by hook operation.
  *         - Each of those arrays have a key of 'runs when' and a value which is
  *           an English description of the hook.
+ *     - access callback: string that will replace the default access callback
+ *       for the menu item that is created.  Default is user_access()
+ *     - access arguments: array that will replace the default access arguments
+ *       for the menu item that is created.  Default is outermost key, i.e. 
+ *       the module name.
  *
  * For example, the node_hook_info implementation has 'node' as the outermost
  * key, as that's the module it's in. Next it has 'node' as the next key,
Index: modules/trigger/trigger.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/trigger/trigger.module,v
retrieving revision 1.32
diff -u -p -r1.32 trigger.module
--- modules/trigger/trigger.module	26 Apr 2009 09:14:32 -0000	1.32
+++ modules/trigger/trigger.module	1 May 2009 06:02:30 -0000
@@ -99,7 +99,8 @@ function trigger_menu() {
       'title' => $nice_name,
       'page callback' => 'trigger_assign',
       'page arguments' => array($module),
-      'access arguments' => array($module),
+      'access arguments' => isset($hook['access arguments']) ? $hook['access arguments'] : array($module),
+      'access callback' => isset($hook['access callback']) ? $hook['access callback'] : 'user_access',
       'type' => MENU_LOCAL_TASK,
     );
   }
