Make the frontend agnostic to why a trigger can be run manually

This commit is contained in:
Joseph Schorr 2016-09-09 16:54:46 -04:00
parent b979f99964
commit 3f2447d831
4 changed files with 6 additions and 7 deletions

View file

@ -199,9 +199,8 @@ angular.module('quay').directive('repoPanelBuilds', function () {
};
$scope.askRunTrigger = function(trigger) {
if (!trigger.is_connected_user) {
bootbox.alert('For security reasons, only the user that created this trigger can ' +
'manually invoke this trigger');
if (!trigger.can_invoke) {
bootbox.alert('You do not have permission to manually invoke this trigger');
return;
}