Revert "Always add activities for comments to the stream"

This reverts commit 48c41b888c
This commit is contained in:
Joas Schilling 2016-08-17 13:30:32 +02:00
parent 29e45dd5ba
commit f900861485
No known key found for this signature in database
GPG Key ID: E166FD8976B3BAC8
1 changed files with 3 additions and 7 deletions

View File

@ -82,8 +82,8 @@ class Extension implements IExtension {
return array(
self::APP_NAME => [
'desc' => (string) $l->t('<strong>Comments</strong> for files <em>(always listed in stream)</em>'),
'methods' => [self::METHOD_MAIL], // self::METHOD_STREAM is forced true by the default value
'desc' => (string) $l->t('<strong>Comments</strong> for files'),
'methods' => [self::METHOD_MAIL, self::METHOD_STREAM],
],
);
}
@ -278,11 +278,7 @@ class Extension implements IExtension {
*/
public function filterNotificationTypes($types, $filter) {
if ($filter === self::APP_NAME) {
return [self::APP_NAME];
}
if (in_array($filter, ['all', 'by', 'self', 'filter'])) {
$types[] = self::APP_NAME;
return $types;
return array_intersect($types, [self::APP_NAME]);
}
return false;
}