From a0baeea111cb72a167887a46e299cbe9a2aab424 Mon Sep 17 00:00:00 2001 From: Amir Mullagaliev Date: Wed, 15 Sep 2021 17:12:12 +0500 Subject: [PATCH] update error name; update doc comments --- tgverifier.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tgverifier.go b/tgverifier.go index 5adb605..c19eef0 100644 --- a/tgverifier.go +++ b/tgverifier.go @@ -8,8 +8,8 @@ import ( "fmt" ) -// ErrInvalidCreds represents error in case of having invalid Telegram auth credentials -var ErrInvalidCreds = errors.New("invalid telegram creds") +// ErrInvalidCredentials represents error in case of having invalid Telegram auth credentials. +var ErrInvalidCredentials = errors.New("invalid telegram creds") // Credentials are Telegram Login credentials available for parsing from JSON. type Credentials struct { @@ -33,7 +33,7 @@ func (c *Credentials) Verify(token []byte) error { ) if hexAuthCode != c.Hash { - return ErrInvalidCreds + return ErrInvalidCredentials } return nil