if ($old->etype != $this->etype) {
$x->query("SELECT core_enum_seqmax_update('". $this->escape($old->etype) ."')");
}
- if($this->name != $old->name && !empty($this->name) && empty($old->etype) && empty($this->etype)){
+
+ if($this->name != $old->name && !empty($old->name) && empty($old->etype) && empty($this->etype)){
$x->query("UPDATE core_enum SET etype = '". $this->escape($this->name)
."' WHERE etype = '". $this->escape($old->name)."'");
}