You are here

function brightcove_playlist_access in Brightcove Video Connect 7.6

Same name and namespace in other branches
  1. 7.7 brightcove.playlist.inc \brightcove_playlist_access()

Access callback for playlist entities.

1 string reference to 'brightcove_playlist_access'
brightcove_entity_info in ./brightcove.module
Implements hook_entity_info().

File

./brightcove.playlist.inc, line 295
Brightcove playlist related functions.

Code

function brightcove_playlist_access($op, $entity, $account = NULL) {

  // Viewing the playlist should be restricted by the content access the
  // playlist is embedded into.
  // Playlist creation depends on the client anyway so let's grant access and
  // notify user on failure later.
  if ($op == 'view' || $op == 'add' || $op == 'create') {
    return TRUE;
  }
  return brightcove_client_access('use', $entity->client);
}