Fix recording request time

This commit is contained in:
Pellaeon Lin 2014-10-22 13:05:23 +08:00
parent 220811ba84
commit 3442085dc0
1 changed files with 2 additions and 2 deletions

View File

@ -15,9 +15,9 @@ class PendingRegist {
public function save($email) { public function save($email) {
$query = $this->db->prepareQuery( 'INSERT INTO `*PREFIX*registration`' $query = $this->db->prepareQuery( 'INSERT INTO `*PREFIX*registration`'
.' ( `email`, `token`, `requested` ) VALUES( ?, ?, ? )' ); .' ( `email`, `token`, `requested` ) VALUES( ?, ?, NOW() )' );
$token = hash('sha256', Util::generateRandomBytes(30).Config::getSystemValue('passwordsalt', '')); $token = hash('sha256', Util::generateRandomBytes(30).Config::getSystemValue('passwordsalt', ''));
$query->execute(array( $email, $token, time() )); $query->execute(array( $email, $token ));
return $token; return $token;
} }
public function find($email) { public function find($email) {