BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
611f3ad2
Commit
611f3ad2
authored
Apr 20, 2016
by
Timothy Andrew
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix rubocop complaints.
parent
abd8ecca
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
13 deletions
+11
-13
authentication.rb
lib/api/helpers/authentication.rb
+1
-2
core.rb
lib/api/helpers/core.rb
+10
-11
No files found.
lib/api/helpers/authentication.rb
View file @
611f3ad2
...
...
@@ -50,4 +50,4 @@ module API
end
end
end
end
\ No newline at end of file
end
lib/api/helpers/core.rb
View file @
611f3ad2
...
...
@@ -132,7 +132,7 @@ module API
if
params
[
:labels
].
present?
params
[
:labels
].
split
(
','
).
each
do
|
label_name
|
label
=
user_project
.
labels
.
create_with
(
color:
Label
::
DEFAULT_COLOR
).
find_or_initialize_by
(
color:
Label
::
DEFAULT_COLOR
).
find_or_initialize_by
(
title:
label_name
.
strip
)
if
label
.
invalid?
...
...
@@ -274,9 +274,9 @@ module API
bad_request!
(
'Bad file path'
)
unless
file_path
.
start_with?
(
uploads_path
)
UploadedFile
.
new
(
file_path
,
params
[
"
#{
field
}
.name"
],
params
[
"
#{
field
}
.type"
]
||
'application/octet-stream'
,
file_path
,
params
[
"
#{
field
}
.name"
],
params
[
"
#{
field
}
.type"
]
||
'application/octet-stream'
,
)
end
...
...
@@ -288,11 +288,11 @@ module API
# Support download acceleration
case
headers
[
'X-Sendfile-Type'
]
when
'X-Sendfile'
header
[
'X-Sendfile'
]
=
path
body
else
file
FileStreamer
.
new
(
path
)
when
'X-Sendfile'
header
[
'X-Sendfile'
]
=
path
body
else
file
FileStreamer
.
new
(
path
)
end
end
...
...
@@ -348,4 +348,4 @@ module API
end
end
end
end
\ No newline at end of file
end
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