Don't fail if no cover

This commit is contained in:
Las Zenow 2013-07-23 22:41:04 +02:00
parent 9f06d24602
commit 18ad2a25c0

View file

@ -133,8 +133,10 @@ func parseFile(epub *epubgo.Epub) map[string]interface{} {
title, _ := book["title"].(string)
book["file"] = nil
cover, coverSmall := GetCover(epub, title)
book["cover"] = cover
book["coversmall"] = coverSmall
if cover != "" {
book["cover"] = cover
book["coversmall"] = coverSmall
}
book["keywords"] = keywords(book)
return book
}