mirror of
				https://gitlab.com/ytdl-org/youtube-dl.git
				synced 2025-11-04 00:57:07 -05:00 
			
		
		
		
	[utils] Add None check in str_to_int
This commit is contained in:
		@@ -1194,6 +1194,8 @@ def format_bytes(bytes):
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def str_to_int(int_str):
 | 
			
		||||
    if int_str is None:
 | 
			
		||||
        return None
 | 
			
		||||
    int_str = re.sub(r'[,\.]', u'', int_str)
 | 
			
		||||
    return int(int_str)
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user