mirror of
https://github.com/humhub/humhub.git
synced 2025-01-17 06:08:21 +01:00
Fix #2555: Friendship notification category visible even if friendship system deactivated
This commit is contained in:
parent
7d1a321767
commit
a928988195
@ -21,6 +21,7 @@ HumHub Change Log
|
|||||||
- Fix: Invite Users does not respect ManageUsers/ManageGroups permission
|
- Fix: Invite Users does not respect ManageUsers/ManageGroups permission
|
||||||
- Fix: Mail summaries sent in incorrect language
|
- Fix: Mail summaries sent in incorrect language
|
||||||
- Fix: Send button text on request space membership dialog
|
- Fix: Send button text on request space membership dialog
|
||||||
|
- Fix #2555: Friendship notification category visible even if friendship system deactivated
|
||||||
|
|
||||||
1.2.0 (April 16, 2017)
|
1.2.0 (April 16, 2017)
|
||||||
--------------------------------
|
--------------------------------
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
|
|
||||||
namespace humhub\modules\friendship\notifications;
|
namespace humhub\modules\friendship\notifications;
|
||||||
|
|
||||||
|
use humhub\modules\user\models\User;
|
||||||
use Yii;
|
use Yii;
|
||||||
use humhub\modules\notification\components\NotificationCategory;
|
use humhub\modules\notification\components\NotificationCategory;
|
||||||
use humhub\modules\notification\targets\BaseTarget;
|
use humhub\modules\notification\targets\BaseTarget;
|
||||||
@ -61,4 +62,12 @@ class FriendshipNotificationCategory extends NotificationCategory
|
|||||||
return $target->defaultSetting;
|
return $target->defaultSetting;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @inheritdoc
|
||||||
|
*/
|
||||||
|
public function isVisible(User $user = null)
|
||||||
|
{
|
||||||
|
return Yii::$app->getModule('friendship')->getIsEnabled();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user