releasenotes: minor bug fix for index error while serializing
authorRishabh Madan <rishabhmadan96@gmail.com>
Sat, 12 Aug 2017 09:21:42 +0530
changeset 33784 589fda7895da
parent 33783 db6b666ce1e6
child 33785 f7d6978a4da9
releasenotes: minor bug fix for index error while serializing Differential Revision: https://phab.mercurial-scm.org/D356
hgext/releasenotes.py
--- a/hgext/releasenotes.py	Thu Aug 03 15:31:54 2017 +0200
+++ b/hgext/releasenotes.py	Sat Aug 12 09:21:42 2017 +0530
@@ -426,7 +426,7 @@
 
             lines.append('')
 
-    if lines[-1]:
+    if lines and lines[-1]:
         lines.append('')
 
     return '\n'.join(lines)