mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 16:34:31 +08:00
DEV: Prefer \A and \z over ^ and $ in regexes (#19936)
This commit is contained in:

committed by
GitHub

parent
f7907a3645
commit
666536cbd1
@ -173,7 +173,7 @@ module BackupRestore
|
||||
path = Regexp.quote(path)
|
||||
end
|
||||
|
||||
%r{^#{path}[^/]*\.t?gz$}i
|
||||
%r{\A#{path}[^/]*\.t?gz\z}i
|
||||
end
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user