From 73d5d7a2265c9b0936ee26cb8fe8af0610d9375b Mon Sep 17 00:00:00 2001 From: Daniel Friesen Date: Sun, 25 Mar 2012 20:44:57 -0700 Subject: [PATCH] Fix broken email confirmation expiration caused by MWCryptRand changes. Change-Id: I7ef0913074f372b5ace3d14993e0e3a914b9f22c --- includes/User.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/User.php b/includes/User.php index 566dcc7407..42c58ab6c5 100644 --- a/includes/User.php +++ b/includes/User.php @@ -3303,11 +3303,12 @@ class User { global $wgUserEmailConfirmationTokenExpiry; $now = time(); $expires = $now + $wgUserEmailConfirmationTokenExpiry; + $expiration = wfTimestamp( TS_MW, $expires ); $this->load(); $token = MWCryptRand::generateHex( 32 ); $hash = md5( $token ); $this->mEmailToken = $hash; - $this->mEmailTokenExpires = wfTimestamp( TS_MW, $expires ); + $this->mEmailTokenExpires = $expiration; return $token; } -- 2.20.1