Fix case where there're no effective caps

When no effective caps in container, it should be list, not None
Change-Id: I5412edc844ad43223c4b3bda35662a7f7ee43f3a
This commit is contained in:
Sagi Shnaidman 2019-11-15 10:52:23 +02:00
parent 6beea6116a
commit 3a6690c904
1 changed files with 1 additions and 1 deletions

View File

@ -1440,7 +1440,7 @@ class PodmanContainerDiff:
return self._diff_update_and_compare('blkio_weight_device', before, after)
def diffparam_cap_add(self):
before = self.info['effectivecaps']
before = self.info['effectivecaps'] or []
after = self.default_dict['cap_add']
if self.module.params['cap_add'] is not None:
after += ["cap_" + i.lower()