summaryrefslogtreecommitdiff
path: root/app/serializers
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-05-05 12:25:24 +0200
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-05-05 12:25:24 +0200
commit936367538043854c7b093b71ca315b8e469c55a4 (patch)
tree9cf4a769d9cffd234ad00cfadb940bcb14553c07 /app/serializers
parentb6facd8313f2996ffef9be8eb2c98d5146d7a137 (diff)
downloadgitlab-ce-936367538043854c7b093b71ca315b8e469c55a4.tar.gz
Use update build policy instead of new play policy
Diffstat (limited to 'app/serializers')
-rw-r--r--app/serializers/build_action_entity.rb2
-rw-r--r--app/serializers/build_entity.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/app/serializers/build_action_entity.rb b/app/serializers/build_action_entity.rb
index 3eff724ae91..75dda1af709 100644
--- a/app/serializers/build_action_entity.rb
+++ b/app/serializers/build_action_entity.rb
@@ -19,6 +19,6 @@ class BuildActionEntity < Grape::Entity
alias_method :build, :object
def playable?
- build.playable? && can?(request.user, :play_build, build)
+ build.playable? && can?(request.user, :update_build, build)
end
end
diff --git a/app/serializers/build_entity.rb b/app/serializers/build_entity.rb
index 10ba7c90c10..1380b347d8e 100644
--- a/app/serializers/build_entity.rb
+++ b/app/serializers/build_entity.rb
@@ -26,7 +26,7 @@ class BuildEntity < Grape::Entity
alias_method :build, :object
def playable?
- build.playable? && can?(request.user, :play_build, build)
+ build.playable? && can?(request.user, :update_build, build)
end
def detailed_status