From: Matthias Schmidt Date: Tue, 7 May 2019 16:21:15 +0000 (+0200) Subject: Enfore unified directory separators for project path X-Git-Tag: 5.2.0_Alpha_1~102 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4a2e25cfc102fe0bacde7aadc4524cf2eb9db3e3;p=GitHub%2FWoltLab%2FWCF.git Enfore unified directory separators for project path Close #2925 --- diff --git a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php index 0fb83b47b3..2b7f38fd43 100644 --- a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php @@ -136,8 +136,13 @@ class DevtoolsProjectAddForm extends AbstractFormBuilderForm { ->label('wcf.acp.devtools.project.path') ->required() ->addValidator(new FormFieldValidator('validPath', function (TextFormField $formField) { - // ensure that there is a trailing slash - $formField->value(FileUtil::addTrailingSlash($formField->getSaveValue() ?? '')); + // ensure that unified directory separators are used + // and that there is a trailing slash + $formField->value( + FileUtil::addTrailingSlash( + FileUtil::unifyDirSeparator($formField->getSaveValue() ?? '') + ) + ); $path = $formField->getSaveValue();