mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-25 08:10:36 +01:00
[safari] make url regex more lenient
This commit is contained in:
parent
67d95f177c
commit
2a0fcf6113
@ -83,7 +83,7 @@ class SafariIE(SafariBaseIE):
|
|||||||
library/view/[^/]+|
|
library/view/[^/]+|
|
||||||
api/v1/book
|
api/v1/book
|
||||||
)/
|
)/
|
||||||
(?P<course_id>\d+)/
|
(?P<course_id>[^/]+)/
|
||||||
(?:chapter(?:-content)?/)?
|
(?:chapter(?:-content)?/)?
|
||||||
(?P<part>part\d+)\.html
|
(?P<part>part\d+)\.html
|
||||||
'''
|
'''
|
||||||
@ -122,7 +122,7 @@ class SafariCourseIE(SafariBaseIE):
|
|||||||
IE_NAME = 'safari:course'
|
IE_NAME = 'safari:course'
|
||||||
IE_DESC = 'safaribooksonline.com online courses'
|
IE_DESC = 'safaribooksonline.com online courses'
|
||||||
|
|
||||||
_VALID_URL = r'https?://(?:www\.)?safaribooksonline\.com/(?:library/view/[^/]+|api/v1/book)/(?P<id>\d+)/?(?:[#?]|$)'
|
_VALID_URL = r'https?://(?:www\.)?safaribooksonline\.com/(?:library/view/[^/]+|api/v1/book)/(?P<id>[^/]+)/?(?:[#?]|$)'
|
||||||
|
|
||||||
_TESTS = [{
|
_TESTS = [{
|
||||||
'url': 'https://www.safaribooksonline.com/library/view/hadoop-fundamentals-livelessons/9780133392838/',
|
'url': 'https://www.safaribooksonline.com/library/view/hadoop-fundamentals-livelessons/9780133392838/',
|
||||||
|
Loading…
Reference in New Issue
Block a user