Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
heptapod
heptapod
Commits
c11e7d0cb61b
Commit
d75a8297
authored
Sep 29, 2016
by
Robert Speicher
Browse files
Add '.well-known' to the list of reserved namespaces
See
https://gitlab.com/gitlab-org/gitlab-ce/issues/22759
parent
964df4cb75e9
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/validators/namespace_validator.rb
View file @
c11e7d0c
...
...
@@ -5,7 +5,8 @@
# Values are checked for formatting and exclusion from a list of reserved path
# names.
class
NamespaceValidator
<
ActiveModel
::
EachValidator
RESERVED
=
%w(
RESERVED
=
%w[
.well-known
admin
all
assets
...
...
@@ -31,7 +32,7 @@ class NamespaceValidator < ActiveModel::EachValidator
u
unsubscribes
users
)
.
freeze
]
.
freeze
def
validate_each
(
record
,
attribute
,
value
)
unless
value
=~
Gitlab
::
Regex
.
namespace_regex
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment