summaryrefslogtreecommitdiffstats
path: root/bugzilla
diff options
context:
space:
mode:
authorWill Woods <wwoods@redhat.com>2008-08-15 15:42:41 -0400
committerWill Woods <wwoods@redhat.com>2008-08-15 15:42:41 -0400
commit94bd4fce33bc55b5be23aca35ad23b0ac05b92e4 (patch)
tree0a25c0318a47eab72013aa4912f0a5d072354b4e /bugzilla
parentf7f2627754bec10383cf909aa3375a2cf2a9a5f2 (diff)
downloadpython-bugzilla-94bd4fce33bc55b5be23aca35ad23b0ac05b92e4.zip
python-bugzilla-94bd4fce33bc55b5be23aca35ad23b0ac05b92e4.tar.gz
python-bugzilla-94bd4fce33bc55b5be23aca35ad23b0ac05b92e4.tar.xz
clean up update_bug calls
Diffstat (limited to 'bugzilla')
-rw-r--r--bugzilla/bugzilla3.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/bugzilla/bugzilla3.py b/bugzilla/bugzilla3.py
index d730f68..8186111 100644
--- a/bugzilla/bugzilla3.py
+++ b/bugzilla/bugzilla3.py
@@ -191,12 +191,14 @@ class RHBugzilla32(Bugzilla32):
# modification calls go through _update_bug.
# Until then, all of these methods are basically just wrappers around it.
+ # TODO: allow multiple bug IDs
+
def _setstatus(self,id,status,comment='',private=False,private_in_it=False,nomail=False):
'''Set the status of the bug with the given ID.'''
update={'bug_status':status}
if comment:
update['comment'] = comment
- return self._update_bug(ids=[id],updates=update)
+ return self._update_bug(id,update)
def _closebug(self,id,resolution,dupeid,fixedin,comment,isprivate,private_in_it,nomail):
'''Close the given bug. This is the raw call, and no data checking is
@@ -212,7 +214,7 @@ class RHBugzilla32(Bugzilla32):
update['comment'] = comment
if isprivate:
update['commentprivacy'] = True
- return self._update_bug(ids=[id],updates=update)
+ return self._update_bug(id,update)
def _setassignee(self,id,**data):
'''Raw xmlrpc call to set one of the assignee fields on a bug.
@@ -221,7 +223,7 @@ class RHBugzilla32(Bugzilla32):
returns: [$id, $mailresults]'''
# drop empty items
update = dict([(k,v) for k,v in data.iteritems() if v != ''])
- return self._update_bug(ids=[id],updates=update)
+ return self._update_bug(id,update)
def _updatedeps(self,id,blocked,dependson,action):
'''Update the deps (blocked/dependson) for the given bug.
@@ -232,7 +234,7 @@ class RHBugzilla32(Bugzilla32):
raise ValueError, "action must be 'add' or 'delete'"
update={'%s_blocked' % action: blocked,
'%s_dependson' % action: dependson}
- self._update_bug(ids=id,updates=update)
+ self._update_bug(id,update)
def _updatecc(self,id,cclist,action,comment='',nomail=False):
'''Updates the CC list using the action and account list specified.
@@ -258,7 +260,7 @@ class RHBugzilla32(Bugzilla32):
update[which] = text
else:
raise NotImplementedError, "append/prepend not supported yet"
- self._update_bug(ids=[id],updates=update)
+ self._update_bug(id,update)
# TODO: update this when the XMLRPC interface grows requestee support
def _updateflags(self,id,flags):