From 08d7c01637c5286ccb4cb711d533222b769408cb Mon Sep 17 00:00:00 2001 From: Syfaro Date: Sun, 3 Jan 2016 22:50:29 -0600 Subject: [PATCH] Rename all errors to be prefixed with Err. --- bot.go | 2 +- configs.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bot.go b/bot.go index eeb8127..4a02e68 100644 --- a/bot.go +++ b/bot.go @@ -64,7 +64,7 @@ func (bot *BotAPI) MakeRequest(endpoint string, params url.Values) (APIResponse, defer resp.Body.Close() if resp.StatusCode == http.StatusForbidden { - return APIResponse{}, errors.New(APIForbidden) + return APIResponse{}, errors.New(ErrAPIForbidden) } bytes, err := ioutil.ReadAll(resp.Body) diff --git a/configs.go b/configs.go index d1db4ac..740e913 100644 --- a/configs.go +++ b/configs.go @@ -30,8 +30,8 @@ const ( // API errors const ( - // APIForbidden happens when a token is bad - APIForbidden = "forbidden" + // ErrAPIForbidden happens when a token is bad + ErrAPIForbidden = "forbidden" ) // Constant values for ParseMode in MessageConfig