Skip to content
Snippets Groups Projects
Commit e3dfb3fd authored by rswindell's avatar rswindell
Browse files

Bug-fixes: The 'E' restriction is the proper way to determine if a user can

send e-mail or not.
parent a4494170
No related branches found
No related tags found
No related merge requests found
......@@ -26,14 +26,10 @@ else {
error("You can't read messages in this sub!");
}
if(sub=='mail' && user.alias!='Guest') {
template.can_post=true;
}
else {
if(msg_area.sub[sub].can_post) {
template.can_post=true;
}
}
if(sub=='mail')
template.can_post=!(user.security.restrictions&UFLAG_E);
else
template.can_post=msg_area.sub[sub].can_post;
template.idx=msgbase.get_msg_index(false,m);
if(sub=='mail' && template.idx.to!=user.number)
......
......@@ -178,19 +178,11 @@ for(displayed=0;displayed<max_messages && last_offset >= 0;last_offset--) {
displayed++;
}
if(sub=='mail' && user.alias!='Guest') {
template.can_post=true;
}
else {
if(msg_area.sub[sub].can_post) {
template.can_post=true;
}
}
if(sub=='mail') {
template.can_post=!(user.security.restrictions&UFLAG_E);
template.post_button="Create New E-Mail";
}
else {
} else {
template.can_post=msg_area.sub[sub].can_post;
template.post_button="Create New Message";
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment