Commit 6e0cf082 authored by Lin Jen-Shin's avatar Lin Jen-Shin

Inline what it was before for the regexp and message

parent 35674fcd
...@@ -187,8 +187,8 @@ class Project < ActiveRecord::Base ...@@ -187,8 +187,8 @@ class Project < ActiveRecord::Base
validates :creator, presence: true, on: :create validates :creator, presence: true, on: :create
validates :description, length: { maximum: 2000 }, allow_blank: true validates :description, length: { maximum: 2000 }, allow_blank: true
validates :ci_config_file, validates :ci_config_file,
format: { without: Gitlab::Regex.directory_traversal_regex, format: { without: /\.{2}/.freeze,
message: Gitlab::Regex.directory_traversal_regex_message }, message: 'cannot include directory traversal.' },
length: { maximum: 255 }, length: { maximum: 255 },
allow_blank: true allow_blank: true
validates :name, validates :name,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment