Skip to content

Commit 34cce40

Browse files
committed
Remove unnecessary list comprehension - 'any' can take a generator
1 parent ac4f7d3 commit 34cce40

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git/remote.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,7 @@ def urls(self):
542542
if ' Push URL:' in line:
543543
yield line.split(': ')[-1]
544544
except GitCommandError as ex:
545-
if any([msg in str(ex) for msg in ['correct access rights', 'cannot run ssh']]):
545+
if any(msg in str(ex) for msg in ['correct access rights', 'cannot run ssh']):
546546
# If ssh is not setup to access this repository, see issue 694
547547
result = Git().execute(
548548
['git', 'config', '--get', 'remote.%s.url' % self.name]

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy