mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-01-24 22:50:12 +08:00
Merge pull request #3545 from nextcloud/enh/noid/fix-regex
This commit is contained in:
commit
28b8be112f
1 changed files with 1 additions and 1 deletions
|
@ -729,7 +729,7 @@ class ConfigurationManager
|
||||||
// Trim all unwanted chars on both sites
|
// Trim all unwanted chars on both sites
|
||||||
$entry = trim($entry);
|
$entry = trim($entry);
|
||||||
if ($entry !== "") {
|
if ($entry !== "") {
|
||||||
if (!preg_match("#^/[.0-1a-zA-Z/-_]+$#", $entry) && !preg_match("#^[.0-1a-zA-Z_-]+$#", $entry)) {
|
if (!preg_match("#^/[.0-1a-zA-Z/_-]+$#", $entry) && !preg_match("#^[.0-1a-zA-Z_-]+$#", $entry)) {
|
||||||
throw new InvalidSettingConfigurationException("You entered unallowed characters! Problematic is " . $entry);
|
throw new InvalidSettingConfigurationException("You entered unallowed characters! Problematic is " . $entry);
|
||||||
}
|
}
|
||||||
$validDirectories .= rtrim($entry, '/') . PHP_EOL;
|
$validDirectories .= rtrim($entry, '/') . PHP_EOL;
|
||||||
|
|
Loading…
Reference in a new issue