Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
go-gitlab
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
go-gitlab
Commits
4f117743
Commit
4f117743
authored
Sep 07, 2015
by
Sander van Harmelen
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #11 from svanharmelen/dev
Improve error message
parents
f0d4b17b
d65d11d1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
gitlab.go
gitlab.go
+5
-3
No files found.
gitlab.go
View file @
4f117743
...
...
@@ -335,9 +335,11 @@ type ErrorResponse struct {
}
func
(
r
*
ErrorResponse
)
Error
()
string
{
return
fmt
.
Sprintf
(
"%v %v: %d %v %+v"
,
r
.
Response
.
Request
.
Method
,
r
.
Response
.
Request
.
URL
,
r
.
Response
.
StatusCode
,
r
.
Message
,
r
.
Errors
)
path
,
_
:=
url
.
QueryUnescape
(
r
.
Response
.
Request
.
URL
.
Opaque
)
ru
:=
fmt
.
Sprintf
(
"%s://%s%s"
,
r
.
Response
.
Request
.
URL
.
Scheme
,
r
.
Response
.
Request
.
URL
.
Host
,
path
)
return
fmt
.
Sprintf
(
"%v %s: %d %v %+v"
,
r
.
Response
.
Request
.
Method
,
ru
,
r
.
Response
.
StatusCode
,
r
.
Message
,
r
.
Errors
)
}
// An Error reports more details on an individual error in an ErrorResponse.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment