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
98c90aff
Commit
98c90aff
authored
Mar 17, 2016
by
Sander van Harmelen
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #41 from mishak87/patch-1
Allow empty token
parents
480adfd0
d6c1e593
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
gitlab.go
gitlab.go
+3
-1
No files found.
gitlab.go
View file @
98c90aff
...
@@ -230,7 +230,9 @@ func (c *Client) NewRequest(method, path string, opt interface{}) (*http.Request
...
@@ -230,7 +230,9 @@ func (c *Client) NewRequest(method, path string, opt interface{}) (*http.Request
}
}
req
.
Header
.
Set
(
"Accept"
,
"application/json"
)
req
.
Header
.
Set
(
"Accept"
,
"application/json"
)
req
.
Header
.
Set
(
"PRIVATE-TOKEN"
,
c
.
token
)
if
c
.
token
!=
""
{
req
.
Header
.
Set
(
"PRIVATE-TOKEN"
,
c
.
token
)
}
if
c
.
UserAgent
!=
""
{
if
c
.
UserAgent
!=
""
{
req
.
Header
.
Set
(
"User-Agent"
,
c
.
UserAgent
)
req
.
Header
.
Set
(
"User-Agent"
,
c
.
UserAgent
)
}
}
...
...
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