Clear blank lines in more places

This commit is contained in:
bel
2020-04-11 16:08:25 +00:00
parent e4a6a9c22f
commit 15761c5a20
2 changed files with 28 additions and 1 deletions

View File

@@ -73,7 +73,11 @@ func (i *Item) Encode() ([]byte, error) {
}
func (i *Item) Decode(b []byte) error {
return config.Decode(b, i)
if err := config.Decode(b, i); err != nil {
return err
}
i.Content = clearBlankLines(i.Content)
return nil
}
func (i *Item) save(ns1 string, ns ...string) error {