mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
We need to match on .p not just strip '.p' otherwise it will remove any p from the string even if we have no dot
This commit is contained in:
parent
cd73eafec8
commit
d7b0c8ae88
1 changed files with 4 additions and 1 deletions
5
salt/cache/localfs.py
vendored
5
salt/cache/localfs.py
vendored
|
@ -135,7 +135,10 @@ def list_(bank, cachedir):
|
|||
)
|
||||
ret = []
|
||||
for item in items:
|
||||
ret.append(item.rstrip('.p'))
|
||||
if item.endswith('.p'):
|
||||
ret.append(item.rstrip(item[-2:]))
|
||||
else:
|
||||
ret.append(item)
|
||||
return ret
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue