reset queue before return
This commit is contained in:
parent
706c59a9a2
commit
d384a10810
1 changed files with 1 additions and 1 deletions
|
|
@ -54,11 +54,11 @@ class TableFormatter(IFormatter):
|
||||||
for line in self.queue:
|
for line in self.queue:
|
||||||
table.add_row(line)
|
table.add_row(line)
|
||||||
s += getattr(table, self.result_funcname)()
|
s += getattr(table, self.result_funcname)()
|
||||||
|
self.queue = []
|
||||||
if self.return_only:
|
if self.return_only:
|
||||||
return s
|
return s
|
||||||
else:
|
else:
|
||||||
print s.encode('utf-8')
|
print s.encode('utf-8')
|
||||||
self.queue = []
|
|
||||||
|
|
||||||
def format_dict(self, item):
|
def format_dict(self, item):
|
||||||
# format is done in self.flush() by prettytable
|
# format is done in self.flush() by prettytable
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue