mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 05:42:50 +00:00
Simplify and correct comparisons with None.
This commit is contained in:
committed by
Michael DeHaan
parent
2172201795
commit
fa8e653011
@@ -89,7 +89,7 @@ def has_local_mods(dest):
|
||||
os.chdir(dest)
|
||||
cmd = "git status -s"
|
||||
lines = os.popen(cmd).read().splitlines()
|
||||
lines = filter(lambda c: re.search('^\\?\\?.*$',c) == None,lines)
|
||||
lines = filter(lambda c: not re.search('^\\?\\?.*$', c), lines)
|
||||
return len(lines) > 0
|
||||
|
||||
def reset(module,dest,force):
|
||||
|
||||
Reference in New Issue
Block a user