Skip to content

Commit

Permalink
fix: PanoramaCommitAll - False args ignored
Browse files Browse the repository at this point in the history
  • Loading branch information
btorresgil committed May 12, 2021
1 parent 1a53e9b commit c2652eb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions panos/panorama.py
Original file line number Diff line number Diff line change
Expand Up @@ -1082,15 +1082,21 @@ def element(self):
ET.SubElement(body, "description").text = self.description
if self.include_template:
ET.SubElement(body, "include-template").text = "yes"
elif self.include_template is False:
ET.SubElement(body, "include-template").text = "no"
if self.force_template_values:
ET.SubElement(body, "force-template-values").text = "yes"
elif self.force_template_values is False:
ET.SubElement(body, "force-template-values").text = "no"
elif self.style == self.STYLE_TEMPLATE:
body = ET.Element("template")
ET.SubElement(body, "name").text = self.name
if self.description:
ET.SubElement(body, "description").text = self.description
if self.force_template_values:
ET.SubElement(body, "force-template-values").text = "yes"
elif self.force_template_values is False:
ET.SubElement(body, "force-template-values").text = "no"
if self.devices:
de = ET.SubElement(body, "device")
for x in self.devices:
Expand All @@ -1102,6 +1108,8 @@ def element(self):
ET.SubElement(body, "description").text = self.description
if self.force_template_values:
ET.SubElement(body, "force-template-values").text = "yes"
elif self.force_template_values is False:
ET.SubElement(body, "force-template-values").text = "no"
if self.devices:
de = ET.SubElement(body, "device")
for x in self.devices:
Expand Down

0 comments on commit c2652eb

Please sign in to comment.