aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Zotlabs/Module/Regate.php4
-rw-r--r--Zotlabs/Module/Register.php10
-rw-r--r--include/account.php2
3 files changed, 8 insertions, 8 deletions
diff --git a/Zotlabs/Module/Regate.php b/Zotlabs/Module/Regate.php
index b9b1c0d56..2b46d7452 100644
--- a/Zotlabs/Module/Regate.php
+++ b/Zotlabs/Module/Regate.php
@@ -46,7 +46,7 @@ class Regate extends \Zotlabs\Web\Controller {
$nowhhmm = date('Hi');
$day = date('N');
- $now = date('Y-m-d H:i:s');
+ $now = datetime_convert();
$ip = $_SERVER['REMOTE_ADDR'];
$isduty = zar_register_dutystate();
@@ -228,7 +228,7 @@ class Regate extends \Zotlabs\Web\Controller {
return $o;
}
- $now = date('Y-m-d H:i:s');
+ $now = datetime_convert();
$ip = $_SERVER['REMOTE_ADDR'];
$isduty = zar_register_dutystate();
diff --git a/Zotlabs/Module/Register.php b/Zotlabs/Module/Register.php
index b2b72bba1..38bfd1619 100644
--- a/Zotlabs/Module/Register.php
+++ b/Zotlabs/Module/Register.php
@@ -302,11 +302,11 @@ class Register extends Controller {
$cfgdelay = get_config( 'system', 'register_delay' );
$regdelay = calculate_adue( $cfgdelay );
- $regdelay = $regdelay ? $regdelay['due'] : $now;
+ $regdelay = $regdelay ? datetime_convert(date_default_timezone_get(), 'UTC', $regdelay['due']) : $now;
$cfgexpire = get_config('system','register_expire' );
$regexpire = calculate_adue( $cfgexpire );
- $regexpire = $regexpire ? $regexpire['due'] : datetime_convert('UTC', 'UTC', 'now + 99 years');
+ $regexpire = $regexpire ? datetime_convert(date_default_timezone_get(), 'UTC', $regexpire['due']) : datetime_convert('UTC', 'UTC', 'now + 99 years');
// handle an email request that will be verified or an ivitation associated with an email address
if ( $email > '' && ($email_verify || $icdone) ) {
@@ -361,9 +361,9 @@ class Register extends Controller {
dbesc($didx),
dbesc($did2),
dbesc($pass2),
- dbesc(datetime_convert('','',$now)),
- dbesc(datetime_convert('','',$regdelay)),
- dbesc(datetime_convert('','',$regexpire)),
+ dbesc($now),
+ dbesc($regdelay),
+ dbesc($regexpire),
dbesc($email),
dbesc(bin2hex($password)),
dbesc(substr(get_best_language(),0,2)),
diff --git a/include/account.php b/include/account.php
index 1c66e1992..a6067a802 100644
--- a/include/account.php
+++ b/include/account.php
@@ -293,7 +293,7 @@ function create_account_IS_OBSOLETE($arr) {
function create_account_from_register($arr) {
$result = array('success' => false, 'message' => 'rid:' . $arr['reg_id']);
- $now = date('Y-m-d H:i:s');
+ $now = datetime_convert();
// reg_flags 0x0020 = REGISTER_AGREED = register request verified by user @ regate
$register = q("SELECT * FROM register WHERE reg_id = %d AND (reg_flags & 31) = 0 "