removes a duplicated slash
This commit is contained in:
parent
3acded5435
commit
1815d5e088
1 changed files with 1 additions and 3 deletions
|
|
@ -28,11 +28,9 @@ namespace Yavsc.ViewModels.UserFiles
|
|||
throw new NotSupportedException("No user name, no user dir.");
|
||||
UserName = username;
|
||||
var finalPath = username;
|
||||
if (!string.IsNullOrWhiteSpace(path))
|
||||
finalPath += Path.DirectorySeparatorChar + path;
|
||||
if (!finalPath.IsValidYavscPath())
|
||||
throw new InvalidOperationException(
|
||||
$"File name contains invalid chars, using path {finalPath}");
|
||||
$"File name contains invalid chars ({finalPath})");
|
||||
|
||||
dInfo = new DirectoryInfo(
|
||||
userReposPath+Path.DirectorySeparatorChar+finalPath);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue