Avoid use global variable - refs BT#9021

1.9.x
Angel Fernando Quiroz Campos 10 years ago
parent 78098f19be
commit adb1989245
  1. 5
      main/auth/sso/sso.Drupal.class.php

@ -228,14 +228,11 @@ class ssoDrupal {
/**
* Generate the URL for profile editing
* @global array $_user
* @return string If the URL is obtained return the drupal_user_id. Otherwise return false
*/
public function generateProfileEditingURL()
{
global $_user;
$userId = $_user['user_id'];
$userId = api_get_user_id();
$userExtraFieldValue = new ExtraFieldValue('user');
$drupalUserIdData = $userExtraFieldValue->get_values_by_handler_and_field_variable($userId, 'drupal_user_id');

Loading…
Cancel
Save