mirror of
				https://github.com/RicterZ/nhentai.git
				synced 2025-11-04 02:50:55 +01:00 
			
		
		
		
	urlparse for python3
This commit is contained in:
		@@ -1,6 +1,5 @@
 | 
			
		||||
# coding: utf-8
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class _Singleton(type):
 | 
			
		||||
    """ A metaclass that creates a Singleton base class when called. """
 | 
			
		||||
    _instances = {}
 | 
			
		||||
@@ -17,6 +16,8 @@ class Singleton(_Singleton('SingletonMeta', (object,), {})):
 | 
			
		||||
 | 
			
		||||
def urlparse(url):
 | 
			
		||||
    try:
 | 
			
		||||
        import urlparse
 | 
			
		||||
        from urlparse import urlparse
 | 
			
		||||
    except ImportError:
 | 
			
		||||
        import urllib.parse as urlparse
 | 
			
		||||
 | 
			
		||||
    return urlparse(url)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user