Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions libraries/src/Table/Usergroup.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,12 +160,12 @@ public function delete($oid = null)

if ($this->id == 0)
{
throw new \UnexpectedValueException('Global Category not found');
throw new \UnexpectedValueException('Usergroup not found');
}

if ($this->parent_id == 0)
{
throw new \UnexpectedValueException('Root categories cannot be deleted.');
throw new \UnexpectedValueException('Root usergroup cannot be deleted.');
}

if ($this->lft == 0 || $this->rgt == 0)
Expand All @@ -189,9 +189,6 @@ public function delete($oid = null)
throw new \UnexpectedValueException('Left-Right data inconsistency. Cannot delete usergroup.');
}

// Delete the category dependencies
// @todo Remove all related threads, posts and subscriptions

// Delete the usergroup and its children
$query->clear()
->delete($db->quoteName($this->_tbl))
Expand Down