From 56a5b35417fff6a7b18c050f9fb631d754476d38 Mon Sep 17 00:00:00 2001 From: F TEMPEZ Date: Wed, 8 Nov 2023 15:11:54 +0100 Subject: [PATCH] Notification reset --- core/module/user/user.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/module/user/user.php b/core/module/user/user.php index e7e3731..aaafdd9 100644 --- a/core/module/user/user.php +++ b/core/module/user/user.php @@ -1120,9 +1120,14 @@ class user extends common // Id unique incorrecte or $this->getUrl(3) !== md5(json_encode($this->getData(['user', $this->getUrl(2)]))) ) { + $message[0] = ($this->getData(['user', $this->getUrl(2)]) === null) === true ?'Utilisateur inconnu':''; + $message[1] = ($this->getData(['user', $this->getUrl(2), 'forgot']) + 86400 < time()) === true ?'Temps dépassé':''; + $message[2] = ($this->getUrl(3) !== md5(json_encode($this->getData(['user', $this->getUrl(2)])))) === true ?'Id incorrect':''; + // Valeurs en sortie $this->addOutput([ - 'access' => false + 'access' => false, + 'notification' => implode (' | ', $message) ]); } // Accès autorisé