Added two new channels: Errors and Info. These will now emit stuff that is sent via log_infomsg and log_errmsg.
This commit is contained in:
parent
debb34aae9
commit
357ef3a250
2 changed files with 5 additions and 1 deletions
|
|
@ -1,7 +1,7 @@
|
|||
from twisted.python import log
|
||||
|
||||
import session_mgr
|
||||
|
||||
import functions_comsys
|
||||
"""
|
||||
General commonly used functions.
|
||||
"""
|
||||
|
|
@ -47,6 +47,7 @@ def log_errmsg(errormsg):
|
|||
errormsg: (string) The message to be logged.
|
||||
"""
|
||||
log.err('ERROR: %s' % (errormsg,))
|
||||
functions_comsys.send_cmessage("Errors", errormsg)
|
||||
|
||||
def log_infomsg(infomsg):
|
||||
"""
|
||||
|
|
@ -55,6 +56,7 @@ def log_infomsg(infomsg):
|
|||
debugmsg: (string) The message to be logged.
|
||||
"""
|
||||
log.msg('%s' % (infomsg,))
|
||||
functions_comsys.send_cmessage("Info", infomsg)
|
||||
|
||||
def time_format(seconds, style=0):
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue