Remove empty lines

This commit is contained in:
Morten Delenk 2016-07-13 16:58:04 +02:00
parent 37af660977
commit eef13ab723
2 changed files with 2 additions and 2 deletions

View file

@ -40,4 +40,4 @@ class HTMLgen:
styleargs = {"title":self.title,"nav":nav,"main":main,"aside":self.asideHTML,"footer":"Copyright 2016 Morten"}
else:
styleargs = {"title":self.title,"nav":nav,"main":self.asideHTML+main,"aside":"","footer":"Copyright 2016 Morten"}
return self.layout%styleargs
return '\n'.join([line for line in (self.layout%styleargs).split('\n') if line.strip() != ''])

View file

@ -10,7 +10,7 @@ for i in range(count):
if "homepage" in article["tags"]:
html.addArticle(**article)
except:
html.addArticle(**storage.get("articles",i), aid=i)
html.addArticle(aid=i, **storage.get("articles",i))
print("<!DOCTYPE html>")
print(html.renderSite())