mirror of
				https://gitlab.com/ytdl-org/youtube-dl.git
				synced 2025-11-04 03:47:07 -05:00 
			
		
		
		
	Merge pull request #7297 from lalinsky/vidme-deleted
[vidme] Check for deleted videos
This commit is contained in:
		@@ -101,6 +101,10 @@ class VidmeIE(InfoExtractor):
 | 
			
		||||
        # suspended
 | 
			
		||||
        'url': 'https://vid.me/Ox3G',
 | 
			
		||||
        'only_matching': True,
 | 
			
		||||
    }, {
 | 
			
		||||
        # deleted
 | 
			
		||||
        'url': 'https://vid.me/KTPm',
 | 
			
		||||
        'only_matching': True,
 | 
			
		||||
    }, {
 | 
			
		||||
        # no formats in the API response
 | 
			
		||||
        'url': 'https://vid.me/e5g',
 | 
			
		||||
@@ -143,6 +147,11 @@ class VidmeIE(InfoExtractor):
 | 
			
		||||
 | 
			
		||||
        video = response['video']
 | 
			
		||||
 | 
			
		||||
        if video.get('state') == 'deleted':
 | 
			
		||||
            raise ExtractorError(
 | 
			
		||||
                'Vidme said: Sorry, this video has been deleted.',
 | 
			
		||||
                expected=True)
 | 
			
		||||
 | 
			
		||||
        if video.get('state') in ('user-disabled', 'suspended'):
 | 
			
		||||
            raise ExtractorError(
 | 
			
		||||
                'Vidme said: This video has been suspended either due to a copyright claim, '
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user