You are here

function oauth_common_context_list in OAuth 1.0 6.3

Same name and namespace in other branches
  1. 7.4 oauth_common.module \oauth_common_context_list()
  2. 7.3 oauth_common.module \oauth_common_context_list()

Lists all available contexts.

Return value

array

3 calls to oauth_common_context_list()
oauth_common_can_create_consumers in ./oauth_common.module
Deterines if a user has the necessary permissions to create consumers.
oauth_common_form_consumer in ./oauth_common.consumers.inc
The consumer form that is shared by the add and edit page.
oauth_common_perm in ./oauth_common.module
Implementation of hook_perm().
2 string references to 'oauth_common_context_list'
oauth_common_schema in ./oauth_common.install
Implementation of hook_schema().
_oauth_common_oauth_common_context_6200 in updates/update.6200.inc

File

./oauth_common.module, line 551

Code

function oauth_common_context_list() {
  $return = array();
  $contexts = oauth_common_context_load_all();
  if ($contexts) {
    foreach ($contexts as $context) {
      $return[$context->name] = $context->title;
    }
  }
  return $return;
}