diff --git a/server/store/middleware/client/blacklist.go b/server/store/middleware/client/blacklist.go index a5bbfd5..ed675f9 100644 --- a/server/store/middleware/client/blacklist.go +++ b/server/store/middleware/client/blacklist.go @@ -15,9 +15,9 @@ func init() { tracker.RegisterAnnounceMiddleware("client_blacklist", blacklistAnnounceClient) } -// ErrBlockedClient is returned by an announce middleware if the announcing -// Client is disallowed. -var ErrBlockedClient = tracker.ClientError("disallowed client") +// ErrBlacklistedClient is returned by an announce middleware if the announcing +// Client is blacklisted. +var ErrBlacklistedClient = tracker.ClientError("client blacklisted") // blacklistAnnounceClient provides a middleware that only allows Clients to // announce that are not stored in the StringStore. @@ -27,7 +27,7 @@ func blacklistAnnounceClient(next tracker.AnnounceHandler) tracker.AnnounceHandl if err != nil { return err } else if blacklisted { - return ErrBlockedClient + return ErrBlacklistedClient } return next(cfg, req, resp) } diff --git a/server/store/middleware/client/whitelist.go b/server/store/middleware/client/whitelist.go index 51b48e5..980f6cd 100644 --- a/server/store/middleware/client/whitelist.go +++ b/server/store/middleware/client/whitelist.go @@ -30,7 +30,7 @@ func whitelistAnnounceClient(next tracker.AnnounceHandler) tracker.AnnounceHandl if err != nil { return err } else if !whitelisted { - return ErrBlockedClient + return ErrNotWhitelistedClient } return next(cfg, req, resp) }