apollo-backend/internal/reddit/errors.go
2021-08-14 14:07:19 -04:00

21 lines
323 B
Go

package reddit
import (
"errors"
"fmt"
)
type ServerError struct {
StatusCode int
}
func (se ServerError) Error() string {
return fmt.Sprintf("errror from reddit: %d", se.StatusCode)
}
var (
// ErrOauthRevoked .
ErrOauthRevoked = errors.New("oauth revoked")
// ErrTimeout .
ErrTimeout = errors.New("timeout")
)