Some code cleanup + bugfix

Fixed bug in format.py where the last DebateDoc added in the add_docs
method had the same text as the previous doc.