aboutsummaryrefslogtreecommitdiffstats
path: root/clients/http/common.go
diff options
context:
space:
mode:
authorMáximo Cuadros <mcuadros@gmail.com>2016-08-13 20:07:21 +0200
committerMáximo Cuadros <mcuadros@gmail.com>2016-08-13 20:07:21 +0200
commita65bcbc63bef24cf219c63d1b8cfb309c95d1c0f (patch)
tree973644feaf08adc916dab8fb95d1f6c86194c9c1 /clients/http/common.go
parenta6ea9e8dd2eda48c8405f609e0fb444d3717af53 (diff)
downloadgo-git-a65bcbc63bef24cf219c63d1b8cfb309c95d1c0f.tar.gz
clients: new Endpoint implementation and InstallProtocol function
Diffstat (limited to 'clients/http/common.go')
-rw-r--r--clients/http/common.go5
1 files changed, 1 insertions, 4 deletions
diff --git a/clients/http/common.go b/clients/http/common.go
index e7c43d5..a4b86bd 100644
--- a/clients/http/common.go
+++ b/clients/http/common.go
@@ -2,7 +2,6 @@
package http
import (
- "errors"
"fmt"
"net/http"
@@ -10,8 +9,6 @@ import (
"gopkg.in/src-d/go-git.v4/core"
)
-var InvalidAuthMethodErr = errors.New("invalid http auth method: a http.HTTPAuthMethod should be provided.")
-
type HTTPAuthMethod interface {
common.AuthMethod
setAuth(r *http.Request)
@@ -53,7 +50,7 @@ func NewHTTPError(r *http.Response) error {
err := &HTTPError{r}
if r.StatusCode == 404 || r.StatusCode == 401 {
- return core.NewPermanentError(common.NotFoundErr)
+ return core.NewPermanentError(common.ErrNotFound)
}
return core.NewUnexpectedError(err)