[FIX] Typo
bzr revid: stephane@tinyerp.com-20081127080158-mteq5ovquyqbdihh
This commit is contained in:
@@ -149,7 +149,7 @@ class db(netsvc.Service):
|
||||
try:
|
||||
cr.execute('DROP DATABASE ' + db_name)
|
||||
except:
|
||||
logger.notifyChannel("web-service", netsvc.LOG_ERROR,
|
||||
logger.notifyChannel("web-services", netsvc.LOG_ERROR,
|
||||
'DROP DB: %s failed' % (db_name,))
|
||||
raise
|
||||
else:
|
||||
@@ -177,7 +177,7 @@ class db(netsvc.Service):
|
||||
data = stdout.read()
|
||||
res = stdout.close()
|
||||
if res:
|
||||
logger.notifyChannel("web-service", netsvc.LOG_ERROR,
|
||||
logger.notifyChannel("web-services", netsvc.LOG_ERROR,
|
||||
'DUMP DB: %s failed\n%s' % (db_name, data))
|
||||
raise Exception, "Couldn't dump database"
|
||||
logger.notifyChannel("web-services", netsvc.LOG_INFO,
|
||||
@@ -189,7 +189,7 @@ class db(netsvc.Service):
|
||||
logger = netsvc.Logger()
|
||||
|
||||
if self.db_exist(db_name):
|
||||
logger.notifyChannel("web-service", netsvc.LOG_WARNING,
|
||||
logger.notifyChannel("web-services", netsvc.LOG_WARNING,
|
||||
'RESTORE DB: %s already exists' % (db_name,))
|
||||
raise Exception, "Database already exists"
|
||||
|
||||
@@ -318,7 +318,7 @@ class common(netsvc.Service):
|
||||
res = security.login(db, login, password)
|
||||
logger = netsvc.Logger()
|
||||
msg = res and 'successful login' or 'bad login or password'
|
||||
logger.notifyChannel("web-service", netsvc.LOG_INFO, "%s from '%s' using database '%s'" % (msg, login, db.lower()))
|
||||
logger.notifyChannel("web-services", netsvc.LOG_INFO, "%s from '%s' using database '%s'" % (msg, login, db.lower()))
|
||||
return res or False
|
||||
|
||||
def about(self, extended=False):
|
||||
@@ -470,7 +470,7 @@ class report_spool(netsvc.Service):
|
||||
tb_s = reduce(lambda x, y: x+y, traceback.format_exception(
|
||||
sys.exc_type, sys.exc_value, sys.exc_traceback))
|
||||
logger = netsvc.Logger()
|
||||
logger.notifyChannel('web-service', netsvc.LOG_ERROR,
|
||||
logger.notifyChannel('web-services', netsvc.LOG_ERROR,
|
||||
'Exception: %s\n%s' % (str(exception), tb_s))
|
||||
self._reports[id]['exception'] = exception
|
||||
self._reports[id]['state'] = True
|
||||
|
||||
Reference in New Issue
Block a user