Fix #1007
paulfantom committed
Sep 25, 2016 at 11:24 UTC
69c18f4e1ac736e4a3c98c4008d8ec548381fb21
1 file changed
+4
-1
python.d/nginx_log.chart.py
+4
-1
@@ -54,7 +54,10 @@ class Service(LogService):
54
regex = self.regex
55
for line in raw:
56
code = regex.search(line)
57
- beginning = code.group(1)[0]
57
+ try:
58
+ beginning = code.group(1)[0]
59
+ except AttributeError:
60
+ return None
61
62
if beginning == '2':
63
data["2xx"] += 1