summaryrefslogtreecommitdiff
path: root/app/services/files
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-03-24 14:55:14 +0100
committerDouwe Maan <douwe@gitlab.com>2015-03-27 11:09:29 +0100
commitdfe0f9eedf040c6c266161239b6e2ede77c2b7dc (patch)
treeff2c2ea02422b4d67ff98a6f256e1b68f52a3883 /app/services/files
parent3f7531d6f2974ea75ab8e67bc93049f674ddb672 (diff)
downloadgitlab-ce-dfe0f9eedf040c6c266161239b6e2ede77c2b7dc.tar.gz
Use more specific regexes.
Diffstat (limited to 'app/services/files')
-rw-r--r--app/services/files/create_service.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/services/files/create_service.rb b/app/services/files/create_service.rb
index eeafefc25af..23833aa78ec 100644
--- a/app/services/files/create_service.rb
+++ b/app/services/files/create_service.rb
@@ -12,10 +12,10 @@ module Files
file_name = File.basename(path)
file_path = path
- unless file_name =~ Gitlab::Regex.path_regex
+ unless file_name =~ Gitlab::Regex.file_name_regex
return error(
'Your changes could not be committed, because the file name ' +
- Gitlab::Regex.path_regex_message
+ Gitlab::Regex.file_name_regex_message
)
end