diff options
author | mathieui <mathieui@mathieui.net> | 2014-10-31 19:15:57 +0100 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2014-10-31 19:16:44 +0100 |
commit | 1c1ab3cb839e5509db52770e10c7190f844eb2e5 (patch) | |
tree | b331060b3dc42651e61e4ccb2dfe6af5e2e97752 /src/logger.py | |
parent | cedc5a6ec80a46437f42464415fd1806049c593d (diff) | |
parent | ea2b703bfd07d293ba9fdd85ac657275d43da2a7 (diff) | |
download | poezio-1c1ab3cb839e5509db52770e10c7190f844eb2e5.tar.gz poezio-1c1ab3cb839e5509db52770e10c7190f844eb2e5.tar.bz2 poezio-1c1ab3cb839e5509db52770e10c7190f844eb2e5.tar.xz poezio-1c1ab3cb839e5509db52770e10c7190f844eb2e5.zip |
Merge branch 'master' of git.poez.io:poezio into slix
Conflicts:
src/bookmark.py
src/config.py
src/connection.py
src/core/commands.py
src/core/core.py
src/core/handlers.py
src/windows/info_bar.py
src/windows/muc.py
src/windows/roster_win.py
src/windows/text_win.py
src/xhtml.py
Diffstat (limited to 'src/logger.py')
-rw-r--r-- | src/logger.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/logger.py b/src/logger.py index 7ed0692f..85c7a746 100644 --- a/src/logger.py +++ b/src/logger.py @@ -50,7 +50,7 @@ class Logger(object): and also log the conversations to logfiles """ def __init__(self): - self.logfile = config.get('logfile', 'logs') + self.logfile = config.get('logfile') self.roster_logfile = None # a dict of 'groupchatname': file-object (opened) self.fds = dict() @@ -78,7 +78,7 @@ class Logger(object): Check that the directory where we want to log the messages exists. if not, create it """ - if not config.get_by_tabname('use_log', True, room): + if not config.get_by_tabname('use_log', room): return try: makedirs(log_dir) @@ -106,10 +106,10 @@ class Logger(object): this function is a little bit more complicated than “read the last nb lines”. """ - if config.get_by_tabname('load_log', 10, jid) <= 0: + if config.get_by_tabname('load_log', jid) <= 0: return - if not config.get_by_tabname('use_log', True, jid): + if not config.get_by_tabname('use_log', jid): return if nb <= 0: @@ -197,7 +197,7 @@ class Logger(object): return True jid = str(jid).replace('/', '\\') - if not config.get_by_tabname('use_log', False, jid): + if not config.get_by_tabname('use_log', jid): return True if jid in self.fds.keys(): fd = self.fds[jid] @@ -245,7 +245,7 @@ class Logger(object): """ Log a roster change """ - if not config.get_by_tabname('use_log', False, jid): + if not config.get_by_tabname('use_log', jid): return True self.check_and_create_log_dir('', open_fd=False) if not self.roster_logfile: |