mirror of
https://github.com/correl/SleekXMPP.git
synced 2024-11-27 19:19:54 +00:00
Fixed line lengths in ElementBase to comply with PEP8.
This commit is contained in:
parent
d68bc2ba07
commit
e16b37d2be
1 changed files with 6 additions and 5 deletions
|
@ -257,8 +257,8 @@ class ElementBase(object):
|
||||||
for stanza in self.iterables:
|
for stanza in self.iterables:
|
||||||
iterables.append(stanza.getStanzaValues())
|
iterables.append(stanza.getStanzaValues())
|
||||||
iterables[-1].update({
|
iterables[-1].update({
|
||||||
'__childtag__': "{%s}%s" % (stanza.namespace, stanza.name)
|
'__childtag__': "{%s}%s" % (stanza.namespace,
|
||||||
})
|
stanza.name)})
|
||||||
values['substanzas'] = iterables
|
values['substanzas'] = iterables
|
||||||
return values
|
return values
|
||||||
|
|
||||||
|
@ -556,9 +556,10 @@ class ElementBase(object):
|
||||||
if parent is None:
|
if parent is None:
|
||||||
parent = self.xml
|
parent = self.xml
|
||||||
for element in elements:
|
for element in elements:
|
||||||
if element.tag == original_target or not element.getchildren():
|
if element.tag == original_target or \
|
||||||
# Only delete the originally requested elements, and any
|
not element.getchildren():
|
||||||
# parent elements that have become empty.
|
# Only delete the originally requested elements, and
|
||||||
|
# any parent elements that have become empty.
|
||||||
parent.remove(element)
|
parent.remove(element)
|
||||||
if not all:
|
if not all:
|
||||||
# If we don't want to delete elements up the tree, stop
|
# If we don't want to delete elements up the tree, stop
|
||||||
|
|
Loading…
Reference in a new issue