From 5217a4244093662fd2ff403c1aeb4632bacb0d96 Mon Sep 17 00:00:00 2001 From: deuce <> Date: Fri, 3 Dec 2004 07:44:15 +0000 Subject: [PATCH] Only display messages you're allowed to read. --- web/root/msgs/msg.ssjs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/web/root/msgs/msg.ssjs b/web/root/msgs/msg.ssjs index da540b453c..e925d50d3b 100644 --- a/web/root/msgs/msg.ssjs +++ b/web/root/msgs/msg.ssjs @@ -20,8 +20,13 @@ if(sub=='mail') { } else { template.sub=msg_area.grp_list[g].sub_list[s]; + if(!msg_area.grp_list[g].sub_list[s].can_read) + error("You can't read messages in this sub!"); } +template.idx=msgbase.get_msg_index(false,m); +if(sub=='mail' && tempalte.idx.to!=user.number) + error("You can only read e-mail messages addressed to yourself!"); template.hdr=msgbase.get_msg_header(false,m); template.body=msgbase.get_msg_body(false,m,true,true); -- GitLab