summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-04-02 12:08:18 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-04-02 12:08:18 +0000
commit684d65316ac77c62f47d68b9926eea8af30db227 (patch)
treed1f4c4eec399d7772ab4ad6294f98e7505c1cee5 /config
parentade18c9d68d5a2e6c6e28ef7e9d3add3b3491ace (diff)
downloadgitlab-ce-684d65316ac77c62f47d68b9926eea8af30db227.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'config')
-rw-r--r--config/initializers/grape_validators.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/config/initializers/grape_validators.rb b/config/initializers/grape_validators.rb
new file mode 100644
index 00000000000..9d2b6dc9bd1
--- /dev/null
+++ b/config/initializers/grape_validators.rb
@@ -0,0 +1,9 @@
+# frozen_string_literal: true
+
+Grape::Validations.register_validator(:absence, ::API::Validations::Validators::Absence)
+Grape::Validations.register_validator(:file_path, ::API::Validations::Validators::FilePath)
+Grape::Validations.register_validator(:git_ref, ::API::Validations::Validators::GitRef)
+Grape::Validations.register_validator(:git_sha, ::API::Validations::Validators::GitSha)
+Grape::Validations.register_validator(:integer_none_any, ::API::Validations::Validators::IntegerNoneAny)
+Grape::Validations.register_validator(:array_none_any, ::API::Validations::Validators::ArrayNoneAny)
+Grape::Validations.register_validator(:check_assignees_count, ::API::Validations::Validators::CheckAssigneesCount)