Don't connect to the database when no bug ids are found for changegroup hooks. default tip
Don't connect to the database when no bug ids are found for changegroup hooks.
1.1 --- a/bugzilla.py Mon Apr 11 16:13:25 2011 -0700
1.2 +++ b/bugzilla.py Sun May 01 12:02:10 2011 -0700
1.3 @@ -480,8 +480,9 @@
1.4 if ids:
1.5 for id in ids:
1.6 bz.add_update(id, ctx)
1.7 - bz.update()
1.8 - bz.notify()
1.9 + if bz.bugs:
1.10 + bz.update()
1.11 + bz.notify()
1.12 else:
1.13 raise util.Abort(_('hook type %s not supported') % hooktype)
1.14 except MySQLdb.MySQLError, err: