Add documentation
This commit is contained in:
parent
1e298dbb10
commit
daf27a0497
@ -1401,24 +1401,14 @@ sub _handle_signin {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
# FIXME: OVERHAUL
|
## @method private @ _handle_default()
|
||||||
sub _handle_signout {
|
# Handle the situation where no specific login function has been selected
|
||||||
my $self = shift;
|
# by the user. This will pick up signed-in users and either redirect them
|
||||||
|
# or make them change their password, and if there's no logged in user
|
||||||
# User must be logged in to log out
|
# this delegates to _handle_signin() to show the signin form.
|
||||||
return $self -> _generate_not_loggedin()
|
#
|
||||||
if($self -> {"session"} -> anonymous_session());
|
# @return An array containing the page title, content, extra header data, and
|
||||||
|
# extra javascript content.
|
||||||
# User is logged in, do the signout
|
|
||||||
$self -> log("signout", $self -> {"session"} -> get_session_userid());
|
|
||||||
if($self -> {"session"} -> delete_session()) {
|
|
||||||
return $self -> _generate_signedout();
|
|
||||||
} else {
|
|
||||||
return $self -> generate_errorbox($SessionHandler::errstr);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
sub _handle_default {
|
sub _handle_default {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
|
|
||||||
@ -1448,6 +1438,30 @@ sub _handle_default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# FIXME: OVERHAUL
|
||||||
|
sub _handle_signout {
|
||||||
|
my $self = shift;
|
||||||
|
|
||||||
|
# User must be logged in to log out
|
||||||
|
return $self -> _generate_not_loggedin()
|
||||||
|
if($self -> {"session"} -> anonymous_session());
|
||||||
|
|
||||||
|
# User is logged in, do the signout
|
||||||
|
$self -> log("signout", $self -> {"session"} -> get_session_userid());
|
||||||
|
if($self -> {"session"} -> delete_session()) {
|
||||||
|
return $self -> _generate_signedout();
|
||||||
|
} else {
|
||||||
|
return $self -> generate_errorbox($SessionHandler::errstr);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
## @method private $ _dispatch_ui()
|
||||||
|
# Implements the core behaviour dispatcher for non-api functions. This will
|
||||||
|
# inspect the state of the pathinfo and invoke the appropriate handler
|
||||||
|
# function to generate content for the user.
|
||||||
|
#
|
||||||
|
# @return A string containing the page HTML.
|
||||||
sub _dispatch_ui {
|
sub _dispatch_ui {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user