arvvoid / plugin.video.hbogoeu

hGO EU, inputstream.adaptive based add-on to access HBO Go content from Kodi
https://arvvoid.github.io/plugin.video.hbogoeu/
GNU General Public License v2.0
125 stars 46 forks source link

Fix duplicated line breaks in subtitles converted to srt #108

Closed Paco8 closed 4 years ago

Paco8 commented 4 years ago

Please check that your pull request pass this checks:

Types of changes

Description:

I'm using HBO Spain, I found a problem with a subtitle, this one: https://production-static.hboespana.com/p/3b1f95c-00b2c24d769/5d8cbcca77d341e580d62f3faa42a30c.xml

This subtitle contains \n characters but the conversion function to srt also converts "<br />" to \n, so the resulting srt contains duplicated \n characters, which creates empty lines between the texts:

1
00:00:50,240 --> 00:00:55,560
Le he dicho: "Señora,

los asientos no han encogido...

2
00:00:55,720 --> 00:00:58,600
...es su trasero el que ha crecido".

3
00:01:41,040 --> 00:01:44,640
Lo siento, señor. Esta cabina

es solo para primera clase.

When this happens kodi only displays the first line of the text.

I think the problem can be fixed just by removing the "\n" characters from the original text.

arvvoid commented 4 years ago

Hello, tnx