add .torrent link support

This commit is contained in:
bel
2020-12-14 22:06:11 -07:00
parent 262aba9633
commit f884f743c9
3 changed files with 15 additions and 3 deletions

View File

@@ -239,6 +239,10 @@ func TestFindMagnets(t *testing.T) {
s: `here is some magnet:-xt1 and magnet:-xt2 another one <a href="magnet:-xt3">link</a>`,
l: 3,
},
{
s: `here is a link https://my.domain/a.b/c.torrent, and another <a href="https://my.domain/a/b/c.torrent"></a>`,
l: 2,
},
}
for i, c := range cases {