summaryrefslogtreecommitdiff
path: root/lib/api/lint.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/api/lint.rb')
-rw-r--r--lib/api/lint.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/api/lint.rb b/lib/api/lint.rb
index a7672021db0..a5995d6dcb3 100644
--- a/lib/api/lint.rb
+++ b/lib/api/lint.rb
@@ -3,20 +3,20 @@
module API
class Lint < Grape::API
namespace :ci do
- desc 'Validation of .gitlab-ci.yml content'
+ desc "Validation of .gitlab-ci.yml content"
params do
- requires :content, type: String, desc: 'Content of .gitlab-ci.yml'
+ requires :content, type: String, desc: "Content of .gitlab-ci.yml"
end
- post '/lint' do
+ post "/lint" do
error = Gitlab::Ci::YamlProcessor.validation_message(params[:content],
user: current_user)
status 200
if error.blank?
- { status: 'valid', errors: [] }
+ {status: "valid", errors: []}
else
- { status: 'invalid', errors: [error] }
+ {status: "invalid", errors: [error]}
end
end
end