From 28f900202becbdc6ab0d944557353fcc075d5b24 Mon Sep 17 00:00:00 2001 From: Vo Minh Thu Date: Fri, 9 Sep 2011 13:39:16 +0200 Subject: [FIX] document_ftp/document_webdav: correctly fix what was incorrectly fixed in revno 4821, revision-id tfr@openerp.com-20110628141309-oag99snygj3vuqwn : pooler.get_db_only was removed from the server but not from the addons. It seems the commit 4821 tried to solved the situation by using get_db instead, which is wrong and it will load the db instead of just trying to get a cursor. This commit solves correctly the removel of get_db_only: by using sql_db.db_connect (for which get_db_only was an alias). bzr revid: vmt@openerp.com-20110909113916-td9o8yct0u5bitb6 --- addons/document_webdav/dav_fs.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'addons/document_webdav/dav_fs.py') diff --git a/addons/document_webdav/dav_fs.py b/addons/document_webdav/dav_fs.py index 5e01bf6a66c..d21dcdc0335 100644 --- a/addons/document_webdav/dav_fs.py +++ b/addons/document_webdav/dav_fs.py @@ -19,6 +19,7 @@ # ############################################################################## import pooler +import sql_db import os import time @@ -361,7 +362,7 @@ class openerp_dav_handler(dav_interface): for db_name in result: cr = None try: - db = pooler.get_db(db_name) + db = sql_db.db_connect(db_name) cr = db.cursor() cr.execute("SELECT id FROM ir_module_module WHERE name = 'document' AND state='installed' ") res=cr.fetchone() -- cgit v1.2.3