diff options
author | Kamil Trzciński <ayufan@ayufan.eu> | 2017-12-18 13:08:51 +0000 |
---|---|---|
committer | Kamil Trzciński <ayufan@ayufan.eu> | 2017-12-18 13:08:51 +0000 |
commit | 924e00496c7d16887447b9384b66b555e5a9f911 (patch) | |
tree | ddf51b4cef3aa68eef7450a4c00eb28084f80eb9 /app/models/repository.rb | |
parent | 38dd7263e15e84c08b62c97028e943c759384b94 (diff) | |
parent | 4b0465f20de1bf58326c7daf6876b63438f00d84 (diff) | |
download | gitlab-ce-924e00496c7d16887447b9384b66b555e5a9f911.tar.gz |
Merge branch 'sh-add-schedule-pipeline-run-now' into 'master'
Add button to run scheduled pipeline immediately
Closes #38741
See merge request gitlab-org/gitlab-ce!15700
Diffstat (limited to 'app/models/repository.rb')
-rw-r--r-- | app/models/repository.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/models/repository.rb b/app/models/repository.rb index 552a354d1ce..4ec8ec9c8b2 100644 --- a/app/models/repository.rb +++ b/app/models/repository.rb @@ -221,6 +221,12 @@ class Repository branch_names.include?(branch_name) end + def tag_exists?(tag_name) + return false unless raw_repository + + tag_names.include?(tag_name) + end + def ref_exists?(ref) !!raw_repository&.ref_exists?(ref) rescue ArgumentError |