diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-11-03 12:54:10 +0100 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-11-03 13:27:00 +0100 |
commit | 573921cb9d0b139dec324fb1368feb1347b51624 (patch) | |
tree | 048c3f8a4c05127a0fc1be1de6ad60b6165bcb32 /app/serializers/commit_entity.rb | |
parent | f1e9c97d64b96bdd398616743ad048f8d147e26b (diff) | |
download | gitlab-ce-573921cb9d0b139dec324fb1368feb1347b51624.tar.gz |
Implement entities needed for environments folders
Diffstat (limited to 'app/serializers/commit_entity.rb')
-rw-r--r-- | app/serializers/commit_entity.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/serializers/commit_entity.rb b/app/serializers/commit_entity.rb new file mode 100644 index 00000000000..ae53de0c750 --- /dev/null +++ b/app/serializers/commit_entity.rb @@ -0,0 +1,10 @@ +class CommitEntity < API::Entities::RepoCommit + include RequestAwareEntity + + expose :commit_url do |commit| + @urls.namespace_project_tree_url( + @request.project.namespace, + @request.project, + id: commit.id) + end +end |