diff options
author | Brion Vibber <brion@pobox.com> | 2010-05-19 10:59:14 -0700 |
---|---|---|
committer | Brion Vibber <brion@pobox.com> | 2010-05-19 10:59:14 -0700 |
commit | a39a934dd4a133bad6e76fa9a5018cedcb70225c (patch) | |
tree | f82b4248da5447780df322c35ca041956bcd887e /actions/register.php | |
parent | d0ba34e0f32ac71b552302ec875943e0e9236720 (diff) | |
parent | 74a89b1fc37067d91d31bd66922053361eb4e616 (diff) |
Merge branch 'master' of gitorious.org:statusnet/mainline into testing
Diffstat (limited to 'actions/register.php')
-rw-r--r-- | actions/register.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/actions/register.php b/actions/register.php index 7fdbb4ded..2fc7ef921 100644 --- a/actions/register.php +++ b/actions/register.php @@ -74,6 +74,13 @@ class RegisterAction extends Action parent::prepare($args); $this->code = $this->trimmed('code'); + // @todo this check should really be in index.php for all sensitive actions + $ssl = common_config('site', 'ssl'); + if (empty($_SERVER['HTTPS']) && ($ssl == 'always' || $ssl == 'sometimes')) { + common_redirect(common_local_url('register')); + // exit + } + if (empty($this->code)) { common_ensure_session(); if (array_key_exists('invitecode', $_SESSION)) { |