~drupal/drupal/6-stable

« back to all changes in this revision

Viewing changes to modules/user/user.module

  • Committer: David Strauss
  • Date: 2010-08-11 20:54:17 UTC
  • Revision ID: david@fourkitchens.com-20100811205417-lnphb75h8gqkrwsm
Tags: DRUPAL-6-19
DrupalĀ 6.19

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<?php
2
 
// $Id: user.module,v 1.892.2.25 2010/06/02 12:47:58 goba Exp $
 
2
// $Id: user.module,v 1.892.2.27 2010/08/06 11:58:09 goba Exp $
3
3
 
4
4
/**
5
5
 * @file
235
235
          if ($value === NULL) {
236
236
            unset($data[$key]);
237
237
          }
238
 
          else {
 
238
          elseif (!empty($key)) {
239
239
            $data[$key] = $value;
240
240
          }
241
241
        }
2527
2527
 
2528
2528
  return empty($groups) ? FALSE : $groups;
2529
2529
}
 
2530
 
 
2531
/**
 
2532
 * Prepare a destination query string for use in combination with drupal_goto().
 
2533
 *
 
2534
 * Used to direct the user back to the referring page after completing
 
2535
 * the openid login.  This function prevents the login page from being
 
2536
 * returned because that page will give an access denied message to an
 
2537
 * authenticated user.
 
2538
 *
 
2539
 * @see drupal_get_destination()
 
2540
 */
 
2541
function user_login_destination() {
 
2542
  $destination = drupal_get_destination();
 
2543
  return $destination == 'destination=user%2Flogin' ? 'destination=user' : $destination;
 
2544
}