From a58300f8d55cd345b12821dcd80728733e2d7bc2 Mon Sep 17 00:00:00 2001 From: Doug Bell Date: Wed, 4 Mar 2009 03:28:48 +0000 Subject: [PATCH] fixed #9852: Users can accept private messages from Visitor, but Visitor cannot send messages --- docs/changelog/7.x.x.txt | 1 + lib/WebGUI/User.pm | 1 + 2 files changed, 2 insertions(+) diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index ca3d6f63f..b67a5e62b 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -7,6 +7,7 @@ - fixed #9819: Survey: hoverhelp showing instead of field name - fixed #9822: Matrix: Wrong field label - fixed #9823: Matrix: no cancel button in add/edit listing + - fixed #9852: Users can accept private messages from Visitor, but Visitor cannot send messages 7.6.13 - fixed AdSpace bug: impressions and clicks for most non-human web clients will not be counted. diff --git a/lib/WebGUI/User.pm b/lib/WebGUI/User.pm index fb9511697..7fb6606db 100644 --- a/lib/WebGUI/User.pm +++ b/lib/WebGUI/User.pm @@ -120,6 +120,7 @@ sub acceptsPrivateMessages { my $userId = shift; return 0 if ($self->isVisitor); #Visitor can't get private messages + return 0 if ($userId eq "1"); # Visitor can't send private messages return 0 if ($self->userId eq $userId); #Can't send private messages to yourself my $pmSetting = $self->profileField('allowPrivateMessages');