re-add redundant client.nick= in tsstats.log.parse_logs to display nick-changes

This commit is contained in:
Thor77 2016-05-19 21:59:34 +02:00
parent 4bb7553f64
commit af3ea48a2d
3 changed files with 3 additions and 2 deletions

View File

@ -56,7 +56,7 @@ author = 'Thor77'
# The short X.Y version. # The short X.Y version.
version = '0.2' version = '0.2'
# The full version, including alpha/beta/rc tags. # The full version, including alpha/beta/rc tags.
release = '0.2.4' release = '0.2.5'
# The language for content autogenerated by Sphinx. Refer to documentation # The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages. # for a list of supported languages.

View File

@ -2,7 +2,7 @@ from setuptools import setup
setup( setup(
name='tsstats', name='tsstats',
version='0.2.4', version='0.2.5',
author='Thor77', author='Thor77',
author_email='thor77@thor77.org', author_email='thor77@thor77.org',
description='A simple Teamspeak stats-generator', description='A simple Teamspeak stats-generator',

View File

@ -34,6 +34,7 @@ def parse_logs(log_path, ident_map=None):
if data.startswith('client'): if data.startswith('client'):
nick, clid = re_dis_connect.findall(data)[0] nick, clid = re_dis_connect.findall(data)[0]
client = clients.setdefault(clid, Client(clid, nick)) client = clients.setdefault(clid, Client(clid, nick))
client.nick = nick # set nick to display changes
if data.startswith('client connected'): if data.startswith('client connected'):
client.connect(logdatetime) client.connect(logdatetime)
elif data.startswith('client disconnected'): elif data.startswith('client disconnected'):