1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-12-28 10:46:15 +01:00

fix set devel project, if no project or package is set

This commit is contained in:
Adrian Schröter 2009-07-28 14:50:23 +00:00
parent 2900aecea4
commit 4df5334115

View File

@ -3778,11 +3778,13 @@ def setDevelProject(apiurl, prj, pac, dprj, dpkg=None):
if dprj:
elem.attrib['project'] = dprj
else:
del elem.attrib['project']
if elem.attrib.has_key('project'):
del elem.attrib['project']
if dpkg:
elem.attrib['package'] = dpkg
else:
del elem.attrib['package']
if elem.attrib.has_key('package'):
del elem.attrib['package']
edit_meta(metatype='pkg',
path_args=path,
data=ET.tostring(tree))