Commit 8706d8d3 authored by Evan Prodromou's avatar Evan Prodromou

double-check profile

parent ad1649e4
...@@ -2474,7 +2474,7 @@ class Notice extends Managed_DataObject ...@@ -2474,7 +2474,7 @@ class Notice extends Managed_DataObject
$author = $this->getProfile(); $author = $this->getProfile();
if ($author->hasRole(Profile_role::SILENCED)) { if ($author->hasRole(Profile_role::SILENCED)) {
if (!$profile->hasRole(Profile_role::MODERATOR)) { if (empty($profile) || !$profile->hasRole(Profile_role::MODERATOR)) {
return true; return true;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment