mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
test: fix spec
This commit is contained in:
@@ -24,6 +24,9 @@ get:
|
||||
error:
|
||||
type: string
|
||||
description: Translation key for client-side localisation
|
||||
alreadyValidated:
|
||||
type: boolean
|
||||
description: set to true if the email was already validated
|
||||
required:
|
||||
- title
|
||||
- $ref: ../../components/schemas/CommonProps.yaml#/CommonProps
|
||||
@@ -227,7 +227,7 @@ Controllers.confirmEmail = async (req, res) => {
|
||||
});
|
||||
}
|
||||
try {
|
||||
if (req.uid) {
|
||||
if (req.loggedIn) {
|
||||
const emailValidated = await user.getUserField(req.uid, 'email:confirmed');
|
||||
if (emailValidated) {
|
||||
return renderPage({ alreadyValidated: true });
|
||||
|
||||
Reference in New Issue
Block a user