On the user's "my account"-page ("user/$uid"), the "View recent links"-link points to "userlink/$uid", which is a listing of that user's links sorted by category. It would make alot more sense if it would link to "userlink/$uid/recent" instead.

/**
 * Implementation of hook_user().
 */
function userlink_user($type, &$edit, &$user) {
  if ($type == 'view' && user_access('view all userlinks', $user)) {
    $items[] = array('title' => t('Links'),
      'value' => l(t("View recent links."), "userlink/$user->uid", array('title' => t("Read %username's links.", array('%username' => $user->name)))),
      'class' => 'userlink',
    );
    return array(t('History') => $items);
  }
}

becomes

/**
 * Implementation of hook_user().
 */
function userlink_user($type, &$edit, &$user) {
  if ($type == 'view' && user_access('view all userlinks', $user)) {
    $items[] = array('title' => t('Links'),
      'value' => l(t("View recent links."), "userlink/$user->uid/recent", array('title' => t("Read %username's links.", array('%username' => $user->name)))),
      'class' => 'userlink',
    );
    return array(t('History') => $items);
  }
}

Comments

satori1984’s picture

Status: Needs review » Closed (fixed)

Closed in favor of node/86345.