Make str.join()s more efficient

by using generator expressions and tuples instead of lists.
This commit is contained in:
Nicola Soranzo
2020-01-23 11:06:32 +00:00
parent 5ef8b4800c
commit f5cd88465e
75 changed files with 121 additions and 121 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ def make_url(api_key, url, args=None):
argsep = '?'
if '?key=' not in url and '&key=' not in url:
args.insert(0, ('key', api_key))
return url + argsep + '&'.join(['='.join(t) for t in args])
return url + argsep + '&'.join('='.join(t) for t in args)
def get(api_key, url):