public function delete($where = [], $options = [])
{
if (isset($where['BanID'])) {
$OldBan = $this->getID($where['BanID'], DATASET_TYPE_ARRAY);
}
$result = parent::delete($where, $options);
if (isset($OldBan)) {
$this->ApplyBan(null, $OldBan);
}
return $result;
}