forked from tpd94/CDRM-Project
		
	Refactor proxy handling in api_decrypt.py to use an empty string instead of None for improved consistency; update returned_keys check to compare against an empty string for better error handling.
This commit is contained in:
		
							parent
							
								
									7f9f04d829
								
							
						
					
					
						commit
						db7bea7951
					
				@ -314,8 +314,8 @@ def api_decrypt(
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
    # Prepare proxies
 | 
			
		||||
    proxies = None
 | 
			
		||||
    if proxy is not None:
 | 
			
		||||
    proxies = ""
 | 
			
		||||
    if proxy != "":
 | 
			
		||||
        is_url, protocol, fqdn = is_url_and_split(proxy)
 | 
			
		||||
        if is_url:
 | 
			
		||||
            proxies = {"http": proxy, "https": proxy}
 | 
			
		||||
@ -380,7 +380,7 @@ def api_decrypt(
 | 
			
		||||
        json_data,
 | 
			
		||||
        is_widevine=(not is_pr),
 | 
			
		||||
    )
 | 
			
		||||
    if returned_keys is None:
 | 
			
		||||
    if returned_keys == "":
 | 
			
		||||
        return {"status": "error", "message": key_err}
 | 
			
		||||
 | 
			
		||||
    # Close session
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user