diff --git a/bureau/class/m_dom.php b/bureau/class/m_dom.php index 1ffa29c4..d579e930 100644 --- a/bureau/class/m_dom.php +++ b/bureau/class/m_dom.php @@ -877,7 +877,7 @@ class m_dom { } if (! is_null($type_old )) { // It's not a creation, it's an edit. Delete the old one - $db->query("update sub_domaines set web_action='DELETE' where domaine='$dom' and sub='$sub' and upper(type)=upper('$type_old') and valeur='$value_old';"); + $db->query("update sub_domaines set web_action='DELETE' where domaine='$dom' and sub='$sub_old' and upper(type)=upper('$type_old') and valeur='$value_old';"); } // Re-create the one we want diff --git a/bureau/class/m_mysql.php b/bureau/class/m_mysql.php index ded4e06f..b4ff09e4 100644 --- a/bureau/class/m_mysql.php +++ b/bureau/class/m_mysql.php @@ -252,6 +252,7 @@ class m_mysql { $login=$db->f("login"); // Ok, database exists and dbname is compliant. Let's proceed + $db->query("DELETE FROM size_db WHERE db='$dbname';"); $db->query("DELETE FROM db WHERE uid='$cuid' AND db='$dbname';"); $this->dbus->query("DROP DATABASE `$dbname`;"); $db->query("SELECT COUNT(*) AS cnt FROM db WHERE uid='$cuid';");