@baris Wow, thanks for your detailed input. Hope I can contribute to the community soon after.
guo
Posts
-
Registering - Force email confirmation? -
Registering - Force email confirmation?@guo said in Registering - Force email confirmation?:
@A-Former-User said in Registering - Force email confirmation?:
I'm going to bump this year old topic to see if it can get more attention. I really feel that NodeBB should differentiate between a registered user, and a user who still needs to validate their email.
While these accounts can't post, they can access all sorts of content that I have open to regular user accounts. A work around would to be a secondary group, reward promotion and require something like an introduction post, but this is by no means the standard procedure on a forum.
I know it is an old topic, can anyone give some hints on how to create a group for registered users without email validation? Although this kind of users are not able to post, they can view topics just like the registered one while a guest cannot.
I dig into the code and try to avoid users without email validation from reading posts.
In src/controllers/api.js, I made some changes as:apiController.getPostData = async function (pid, uid) { const [userPrivileges, post, voted, userData] = await Promise.all([ privileges.posts.get([pid], uid), posts.getPostData(pid), posts.hasVoted(pid, uid), user.getUserFields(uid, ['email:confirmed']), // add ]); if (!post) { return null; } Object.assign(post, voted); const notConfirmed = meta.config.requireEmailConfirmation && !userData['email:confirmed']; // add const userPrivilege = userPrivileges[0]; if (!userPrivilege.read || !userPrivilege['topics:read'] || notConfirmed) { // add return null; } post.ip = userPrivilege.isAdminOrMod ? post.ip : undefined; const selfPost = uid && uid === parseInt(post.uid, 10); if (post.deleted && !(userPrivilege.isAdminOrMod || selfPost)) { post.content = '[[topic:post_is_deleted]]'; } return post; };
But it is of no avail. I am a nodejs newbie, can anyone give some advises?
-
Registering - Force email confirmation?@A-Former-User said in Registering - Force email confirmation?:
I'm going to bump this year old topic to see if it can get more attention. I really feel that NodeBB should differentiate between a registered user, and a user who still needs to validate their email.
While these accounts can't post, they can access all sorts of content that I have open to regular user accounts. A work around would to be a secondary group, reward promotion and require something like an introduction post, but this is by no means the standard procedure on a forum.
I know it is an old topic, can anyone give some hints on how to create a group for registered users without email validation? Although this kind of users are not able to post, they can view topics just like the registered one while a guest cannot.