non-existent poco

This commit is contained in:
Evan Prodromou 2012-01-27 15:32:13 -05:00
parent d28f726c5c
commit e4085087f1
1 changed files with 9 additions and 7 deletions

View File

@ -505,14 +505,16 @@ class BlacklistPlugin extends Plugin
}
}
$nickname = strtolower($actor->poco->preferredUsername);
if (!empty($actor->poco)) {
$nickname = strtolower($actor->poco->preferredUsername);
if (!empty($nickname)) {
if (!$this->_checkNickname($nickname)) {
// TRANS: Exception thrown trying to post a notice while having a blocked nickname. %s is the blocked nickname.
$msg = sprintf(_m("Notices from nickname \"%s\" disallowed."),
$nickname);
throw new ClientException($msg);
if (!empty($nickname)) {
if (!$this->_checkNickname($nickname)) {
// TRANS: Exception thrown trying to post a notice while having a blocked nickname. %s is the blocked nickname.
$msg = sprintf(_m("Notices from nickname \"%s\" disallowed."),
$nickname);
throw new ClientException($msg);
}
}
}