aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2008-06-03 15:51:40 +0200
committerDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2008-06-03 15:51:40 +0200
commit84cd55121d726d84d872ea074b7f2c79e6ef7bd5 (patch)
treef217613841bf94af2a5785d26955b7b0074844e7
parentRemove delete_client calls as the client is no more istantiated inside the pl... (diff)
downloadrbot-bugzilla-84cd55121d726d84d872ea074b7f2c79e6ef7bd5.tar.gz
rbot-bugzilla-84cd55121d726d84d872ea074b7f2c79e6ef7bd5.tar.bz2
rbot-bugzilla-84cd55121d726d84d872ea074b7f2c79e6ef7bd5.zip
Don't try to fetch the buglist if there are no announcements for the instance.
This way we avoid fetching a ton of data, and we don't create problems if the instance contains invalid data.
-rw-r--r--bugzilla.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/bugzilla.rb b/bugzilla.rb
index 9fe9e6b..4457a08 100644
--- a/bugzilla.rb
+++ b/bugzilla.rb
@@ -316,6 +316,8 @@ class BugzillaPlugin < Plugin
end
def announce
+ return if @registry["zilla.#{@name}.announcements"].size < 1
+
buglist_url = baseurl +
"/buglist.cgi?ctype=csv&order=bugs.bug_id"