You are here

function sarnia_field_ui_menu_access_callback in Sarnia 7

Check whether a Sarnia bundle Field UI sub-path is valid, and do the access check.

See also

sarnia_menu_alter()

1 string reference to 'sarnia_field_ui_menu_access_callback'
sarnia_menu_alter in ./sarnia.module
Implements hook_menu_alter().

File

./sarnia.module, line 295

Code

function sarnia_field_ui_menu_access_callback($perm, $path) {
  return user_access($perm) && (!$path || in_array($path, array(
    'edit',
    'field-settings',
    'widget-type',
    'delete',
  )));
}