From 831ad524e60928ca0229e429e684058eab460262 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Hanol?= Date: Wed, 12 Feb 2014 20:08:46 -0800 Subject: [PATCH] added some comments --- lib/guardian.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/guardian.rb b/lib/guardian.rb index c8faab5e7bf..65e07b293d4 100644 --- a/lib/guardian.rb +++ b/lib/guardian.rb @@ -177,14 +177,13 @@ class Guardian def can_send_private_message?(target) (User === target || Group === target) && + # User is authenticated authenticated? && - # Can't send message to yourself is_not_me?(target) && - # Have to be a basic level at least @user.has_trust_level?(:basic) && - + # PMs are enabled SiteSetting.enable_private_messages end