forked from GNUsocial/gnu-social
Merge branch '0.9.x' into openidplugin
This commit is contained in:
commit
000e21be19
@ -223,3 +223,7 @@ EndRegistrationTry: after saving a new user (note: no profile or user object!)
|
|||||||
|
|
||||||
StartNewQueueManager: before trying to start a new queue manager; good for plugins implementing new queue manager classes
|
StartNewQueueManager: before trying to start a new queue manager; good for plugins implementing new queue manager classes
|
||||||
- $qm: empty queue manager to set
|
- $qm: empty queue manager to set
|
||||||
|
|
||||||
|
RedirectToLogin: event when we force a redirect to login (like when going to a settings page on a remembered login)
|
||||||
|
- $action: action object being shown
|
||||||
|
- $user: current user
|
||||||
|
@ -77,10 +77,12 @@ class SettingsAction extends CurrentUserDesignAction
|
|||||||
// _all_ our settings are important
|
// _all_ our settings are important
|
||||||
common_set_returnto($this->selfUrl());
|
common_set_returnto($this->selfUrl());
|
||||||
$user = common_current_user();
|
$user = common_current_user();
|
||||||
if ($user->hasOpenID()) {
|
if (Event::handle('RedirectToLogin', array($this, $user))) {
|
||||||
common_redirect(common_local_url('openidlogin'), 303);
|
if ($user->hasOpenID()) {
|
||||||
} else {
|
common_redirect(common_local_url('openidlogin'), 303);
|
||||||
common_redirect(common_local_url('login'), 303);
|
} else {
|
||||||
|
common_redirect(common_local_url('login'), 303);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
} else if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||||
$this->handlePost();
|
$this->handlePost();
|
||||||
|
Loading…
Reference in New Issue
Block a user