fix: removed double linebreaks from formated text, plaintext
This commit is contained in:
parent
98afe5047d
commit
bab6aeb45d
@ -38,8 +38,13 @@ class FormattedText:
|
|||||||
def markdown(self) -> str:
|
def markdown(self) -> str:
|
||||||
return md(self.html).strip()
|
return md(self.html).strip()
|
||||||
|
|
||||||
|
@property
|
||||||
|
def plain(self) -> str:
|
||||||
|
md = self.markdown
|
||||||
|
return md.replace("\n\n", "\n")
|
||||||
|
|
||||||
def __str__(self) -> str:
|
def __str__(self) -> str:
|
||||||
return self.markdown
|
return self.markdown
|
||||||
|
|
||||||
plaintext = markdown
|
plaintext = plain
|
||||||
|
|
||||||
|
@ -34,6 +34,6 @@ class Lyrics(OuterProxy):
|
|||||||
@property
|
@property
|
||||||
def metadata(self) -> Metadata:
|
def metadata(self) -> Metadata:
|
||||||
return Metadata({
|
return Metadata({
|
||||||
id3Mapping.UNSYNCED_LYRICS: [self.text.markdown]
|
id3Mapping.UNSYNCED_LYRICS: [self.text.plaintext]
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user