Fix group-join request rejections

This commit is contained in:
Chimo 2015-12-04 16:09:51 +00:00
parent 831e9db7ec
commit 6d9ea620a3
1 changed files with 4 additions and 7 deletions

View File

@ -76,18 +76,15 @@ class Group_join_queue extends Managed_DataObject
/**
* Abort the pending group join...
*
* @param User_group $group
*/
function abort()
{
$profile = $this->getMember();
$group = $this->getGroup();
if ($request) {
if (Event::handle('StartCancelJoinGroup', array($profile, $group))) {
$this->delete();
Event::handle('EndCancelJoinGroup', array($profile, $group));
}
if (Event::handle('StartCancelJoinGroup', array($profile, $group))) {
$this->delete();
Event::handle('EndCancelJoinGroup', array($profile, $group));
}
}