aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Regapr.php26
-rw-r--r--Zotlabs/Module/Regate.php16
-rw-r--r--Zotlabs/Module/Register.php1
3 files changed, 9 insertions, 34 deletions
diff --git a/Zotlabs/Module/Regapr.php b/Zotlabs/Module/Regapr.php
deleted file mode 100644
index 9e6cb1de8..000000000
--- a/Zotlabs/Module/Regapr.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-namespace Zotlabs\Module;
-
-use Zotlabs\Web\Controller;
-
-class Regapr extends Controller {
-
- function get() {
-
- $o = '';
-
- $did2 = hex2bin(argv(1));
-
- if(!$did2)
- return $o;
-
- $o .= 'Thank you for registering!' . PHP_EOL;
- $o .= 'After your account has been approved by our administrator you will be able to login with your ID' . PHP_EOL;
- $o .= $did2 . PHP_EOL;
- $o .= 'and your provided password.';
-
- return $o;
-
- }
-
-}
diff --git a/Zotlabs/Module/Regate.php b/Zotlabs/Module/Regate.php
index 4fcae83e4..f6faff811 100644
--- a/Zotlabs/Module/Regate.php
+++ b/Zotlabs/Module/Regate.php
@@ -70,8 +70,8 @@ class Regate extends \Zotlabs\Web\Controller {
// check timeframe
if ( $r['reg_startup'] <= $now && $r['reg_expires'] >= $now ) {
if ( isset($_POST['resend']) && $didx == 'e' ) {
- $re = q("SELECT * FROM register WHERE reg_vital = 1 AND reg_didx = 'e' AND reg_did2 = '%s' ", dbesc($r['reg_did2']) );
- if ( $re && count($re) == 1 ) {
+ $re = q("SELECT * FROM register WHERE reg_vital = 1 AND reg_didx = 'e' AND reg_did2 = '%s' ORDER BY reg_created DESC ", dbesc($r['reg_did2']) );
+ if ( $re ) {
$re = $re[0];
$reonar = json_decode($re['reg_stuff'],true);
$reonar['subject'] = 'Re,Fwd,' . $reonar['subject'];
@@ -93,7 +93,8 @@ class Regate extends \Zotlabs\Web\Controller {
$acpin = (preg_match('/^[0-9a-f]{24,24}$/', $_POST['acpin']) ? $_POST['acpin'] : false);
elseif ( $didx == 'i' )
$acpin = $r['reg_hash'];
- else $acpin = false;
+ else
+ $acpin = false;
if ( $acpin && ($r['reg_hash'] == $acpin )) {
@@ -124,7 +125,7 @@ class Regate extends \Zotlabs\Web\Controller {
if ( ($flags & ACCOUNT_PENDING ) == ACCOUNT_PENDING ) {
$msg .= "\n".t('Last step will be by an instance admin to agree your account request');
- $nextpage = 'regapr/' . bin2hex($did2);
+ $nextpage = 'regate/' . bin2hex($did2) . $didx;
q("COMMIT");
}
elseif ( ($flags ^ REGISTER_AGREED) == 0) {
@@ -263,9 +264,10 @@ class Regate extends \Zotlabs\Web\Controller {
$o = replace_macros(get_markup_template('plain.tpl'), [
'$title' => t('Register Verification Status'),
'$now' => $nowfmt,
- '$infos' => t('Soon all is well.') . EOL
- . t('Only one instance admin has still to agree your account request.') . EOL
- . t('Please be patient') . EOL . EOL . 'ZAR1138I',
+ '$infos' => t('Verification successful!') . EOL
+ . t('After your account has been approved by our administrator you will be able to login with your ID') . EOL
+ . $did2 . EOL
+ . t('and your provided password.')
]);
}
else {
diff --git a/Zotlabs/Module/Register.php b/Zotlabs/Module/Register.php
index 98a682611..73eaa5310 100644
--- a/Zotlabs/Module/Register.php
+++ b/Zotlabs/Module/Register.php
@@ -364,7 +364,6 @@ class Register extends Controller {
]
);
pop_lang();
- hz_syslog(print_r($reonar,true));
zar_reg_mail($reonar);
} else {