mirror of
				https://github.com/RicterZ/nhentai.git
				synced 2025-11-04 02:50:55 +01:00 
			
		
		
		
	fix #197 set proxy to null
This commit is contained in:
		@@ -156,7 +156,7 @@ def cmd_parser():
 | 
				
			|||||||
        exit(0)
 | 
					        exit(0)
 | 
				
			||||||
        # TODO: search without language
 | 
					        # TODO: search without language
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if args.proxy:
 | 
					    if args.proxy is not None:
 | 
				
			||||||
        proxy_url = urlparse(args.proxy)
 | 
					        proxy_url = urlparse(args.proxy)
 | 
				
			||||||
        if not args.proxy == '' and proxy_url.scheme not in ('http', 'https'):
 | 
					        if not args.proxy == '' and proxy_url.scheme not in ('http', 'https'):
 | 
				
			||||||
            logger.error('Invalid protocol \'{0}\' of proxy, ignored'.format(proxy_url.scheme))
 | 
					            logger.error('Invalid protocol \'{0}\' of proxy, ignored'.format(proxy_url.scheme))
 | 
				
			||||||
@@ -170,7 +170,7 @@ def cmd_parser():
 | 
				
			|||||||
            write_config()
 | 
					            write_config()
 | 
				
			||||||
            exit(0)
 | 
					            exit(0)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if args.viewer_template:
 | 
					    if args.viewer_template is not None:
 | 
				
			||||||
        if not args.viewer_template:
 | 
					        if not args.viewer_template:
 | 
				
			||||||
            args.viewer_template = 'default'
 | 
					            args.viewer_template = 'default'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,7 +1,6 @@
 | 
				
			|||||||
#
 | 
					#
 | 
				
			||||||
# Copyright (C) 2010-2012 Vinay Sajip. All rights reserved. Licensed under the new BSD license.
 | 
					# Copyright (C) 2010-2012 Vinay Sajip. All rights reserved. Licensed under the new BSD license.
 | 
				
			||||||
#
 | 
					#
 | 
				
			||||||
from __future__ import print_function, unicode_literals
 | 
					 | 
				
			||||||
import logging
 | 
					import logging
 | 
				
			||||||
import re
 | 
					import re
 | 
				
			||||||
import platform
 | 
					import platform
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user