Remove XXX comment about needing an API to enable or disable UI elements, since that need has disappeared now that we use provide that information reliably in the user object. Also split a long line into two for no particular reason.

This commit is contained in:
ian%hixie.ch 2002-07-06 16:12:42 +00:00
Родитель 3d03ce2061
Коммит 9f2b625c88
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -172,7 +172,6 @@ sub cmdLoginSendPassword {
# user.login
# if this returns undef, don't do anything!
# XXX need a quieter version of this to enable/disable UI elements
sub hasRight {
my $self = shift;
my($app, $right) = @_;
@ -199,7 +198,8 @@ sub requireLogin {
$app->getSelectingServiceList('user.login.required.generic')->loginRequired($app);
}
my $address = $app->input->address;
if (defined($address) and not defined($app->getService('user.factory')->getUserByContactDetails($app, $app->input->protocol, $address))) {
if (defined($address) and
not defined($app->getService('user.factory')->getUserByContactDetails($app, $app->input->protocol, $address))) {
my($user, $password) = $self->createUser($app, $app->input->protocol, $address);
$self->sendPassword($app, $user, $app->input->protocol, $password);
return;