You are here

function fasttoggle_preprocess_author_pane in Author Pane 7.2

Same name and namespace in other branches
  1. 5 modules/fasttoggle.author-pane.inc \fasttoggle_preprocess_author_pane()
  2. 6.2 modules/fasttoggle.author-pane.inc \fasttoggle_preprocess_author_pane()
  3. 6 modules/fasttoggle.author-pane.inc \fasttoggle_preprocess_author_pane()

Implements hook_preprocess_author_pane().

File

modules/fasttoggle.author-pane.inc, line 10
This file provides a preprocess function on behalf of the fasttoggle module.

Code

function fasttoggle_preprocess_author_pane(&$variables) {

  // Check if this preprocess needs to be run given who's calling it.
  if (!author_pane_run_preprocess('fasttoggle', $variables['caller'])) {
    return;
  }

  // Do not show fasttoggle links for anonymous users.
  if ($variables['account']->uid != 0) {
    $variables['fasttoggle_links'] = theme('links', array(
      'links' => fasttoggle_link('user', $variables['account']),
      'attributes' => array(
        'class' => 'links inline',
      ),
    ));
  }
}