mirror of
https://github.com/miniflux/v2.git
synced 2025-09-15 18:57:04 +00:00
Try to use outermost element text when title is empty
This commit is contained in:
parent
ec2b911881
commit
fa8431c5c6
2 changed files with 36 additions and 3 deletions
|
@ -245,7 +245,12 @@ func (a *atom10Text) String() string {
|
|||
content = a.InnerXML
|
||||
}
|
||||
case a.Type == "xhtml":
|
||||
content = a.XHTMLRootElement.InnerXML
|
||||
var root = a.XHTMLRootElement
|
||||
if root.XMLName.Local == "div" {
|
||||
content = root.InnerXML
|
||||
} else {
|
||||
content = a.InnerXML
|
||||
}
|
||||
default:
|
||||
content = a.CharData
|
||||
}
|
||||
|
@ -254,5 +259,6 @@ func (a *atom10Text) String() string {
|
|||
}
|
||||
|
||||
type atomXHTMLRootElement struct {
|
||||
InnerXML string `xml:",innerxml"`
|
||||
XMLName xml.Name `xml:"div"`
|
||||
InnerXML string `xml:",innerxml"`
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue