Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
gitlab-ce
Commits
11b57d97
Commit
11b57d97
authored
Mar 11, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reduce amount of user info provided with internal api
parent
a29c883b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
lib/api/entities.rb
lib/api/entities.rb
+4
-0
lib/api/internal.rb
lib/api/internal.rb
+1
-1
No files found.
lib/api/entities.rb
View file @
11b57d97
...
@@ -5,6 +5,10 @@ module Gitlab
...
@@ -5,6 +5,10 @@ module Gitlab
:dark_scheme
,
:theme_id
,
:state
,
:created_at
,
:extern_uid
,
:provider
:dark_scheme
,
:theme_id
,
:state
,
:created_at
,
:extern_uid
,
:provider
end
end
class
UserSafe
<
Grape
::
Entity
expose
:name
end
class
UserBasic
<
Grape
::
Entity
class
UserBasic
<
Grape
::
Entity
expose
:id
,
:username
,
:email
,
:name
,
:state
,
:created_at
expose
:id
,
:username
,
:email
,
:name
,
:state
,
:created_at
end
end
...
...
lib/api/internal.rb
View file @
11b57d97
...
@@ -44,7 +44,7 @@ module Gitlab
...
@@ -44,7 +44,7 @@ module Gitlab
#
#
get
"/discover"
do
get
"/discover"
do
key
=
Key
.
find
(
params
[
:key_id
])
key
=
Key
.
find
(
params
[
:key_id
])
present
key
.
user
,
with:
Entities
::
User
present
key
.
user
,
with:
Entities
::
User
Safe
end
end
get
"/check"
do
get
"/check"
do
...
...
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