aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2020-04-29 15:40:37 +0200
committerDmitry Vyukov <dvyukov@google.com>2020-04-29 16:32:33 +0200
commit08bed8d76911c9f004a2997c550687351faa52ce (patch)
tree1d29890e39d27bb31c15c1c6fb63357809bded11
parent496a08ae323ec183c03c43427675610e6edf5378 (diff)
dashboard/app: fix linter warnings
-rw-r--r--dashboard/app/handler.go5
-rw-r--r--dashboard/app/reporting.go6
2 files changed, 3 insertions, 8 deletions
diff --git a/dashboard/app/handler.go b/dashboard/app/handler.go
index 62294811c..561547793 100644
--- a/dashboard/app/handler.go
+++ b/dashboard/app/handler.go
@@ -104,11 +104,6 @@ type uiNamespace struct {
Caption string
}
-type uiRedirect struct {
- From string
- To string
-}
-
type cookieData struct {
Namespace string `json:"namespace"`
}
diff --git a/dashboard/app/reporting.go b/dashboard/app/reporting.go
index 52941e5db..7892b0b34 100644
--- a/dashboard/app/reporting.go
+++ b/dashboard/app/reporting.go
@@ -161,6 +161,9 @@ func reportingPollNotifications(c context.Context, typ string) []*dashapi.BugNot
log.Infof(c, "fetched %v bugs", len(bugs))
var notifs []*dashapi.BugNotification
for _, bug := range bugs {
+ if config.Namespaces[bug.Namespace].Decommissioned {
+ continue
+ }
notif, err := handleReportNotif(c, typ, bug)
if err != nil {
log.Errorf(c, "%v: failed to create bug notif %v: %v", bug.Namespace, bug.Title, err)
@@ -178,9 +181,6 @@ func reportingPollNotifications(c context.Context, typ string) []*dashapi.BugNot
}
func handleReportNotif(c context.Context, typ string, bug *Bug) (*dashapi.BugNotification, error) {
- if config.Namespaces[bug.Namespace].Decommissioned {
- return nil, nil
- }
reporting, bugReporting, _, _, err := currentReporting(c, bug)
if err != nil || reporting == nil {
return nil, nil