[FIX] KeyError: 'drop_db'. When trying to drop db without db name

lp bug: https://launchpad.net/bugs/966108 fixed

bzr revid: fme@openerp.com-20120328150031-6hdb9rwjoh3stfif
This commit is contained in:
Fabien Meghazi
2012-03-28 17:00:31 +02:00
parent 8d4de6e4e8
commit 179fb5ce69
+1 -1
View File
@@ -410,7 +410,7 @@ openerp.web.Database = openerp.web.OldWidget.extend(/** @lends openerp.web.Datab
$db_list = $form.find('[name=drop_db]'),
db = $db_list.val();
if (!confirm("Do you really want to delete the database: " + db + " ?")) {
if (!db || !confirm("Do you really want to delete the database: " + db + " ?")) {
return;
}
self.rpc("/web/database/drop", {'fields': fields}, function(result) {