From: Royce Lv <lvroyce(a)linux.vnet.ibm.com>
Clean pep8 and add xmlutils.py to clean list.
Signed-off-by: Royce Lv <lvroyce(a)linux.vnet.ibm.com>
---
Makefile.am | 1 +
src/kimchi/xmlutils.py | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/Makefile.am b/Makefile.am
index 04ad696..f39c8a0 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -56,6 +56,7 @@ PEP8_WHITELIST = \
src/kimchi/rollbackcontext.py \
src/kimchi/root.py \
src/kimchi/server.py \
+ src/kimchi/xmlutils.py \
tests/test_mockmodel.py \
tests/test_model.py \
tests/test_plugin.py \
diff --git a/src/kimchi/xmlutils.py b/src/kimchi/xmlutils.py
index f94db30..4686113 100644
--- a/src/kimchi/xmlutils.py
+++ b/src/kimchi/xmlutils.py
@@ -33,7 +33,7 @@ from kimchi.exception import ParseError
def xpath_get_text(xml, expr):
doc = libxml2.parseDoc(xml)
res = doc.xpathEval(expr)
- ret = [None if x.children == None else x.children.content for x in res]
+ ret = [None if x.children is None else x.children.content for x in res]
doc.freeDoc()
return ret
--
1.8.1.2