File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,8 @@ def __init__(
2626 """
2727 # Check arguments
2828 if not file and not any ([api_key , api_url ]):
29- raise ValueError ('Filename or api_key and api_url are expected in Config initialization' )
29+ raise ValueError ('Filename or api_key and api_url are expected'
30+ 'in Config initialization' )
3031 if products and not isinstance (products , (str , list )):
3132 raise TypeError ('Products can be string or string list. Found type '
3233 + type (products ).__name__ )
@@ -50,7 +51,9 @@ def __init__(
5051 configs .get ('products' , '' ))
5152 api_url = api_url .encode ('utf-8' ) if not isinstance (api_url , str ) else api_url
5253 api_key = api_key .encode ('utf-8' ) if not isinstance (api_key , str ) else api_key
53- products = products .encode ('utf-8' ) if not isinstance (products , (str , list )) else products
54+ products = products .encode ('utf-8' ) \
55+ if not isinstance (products , (str , list )) \
56+ else products
5457
5558 # Initialize
5659 self ._api_key = api_key
You can’t perform that action at this time.
0 commit comments