#18677: Fixing BodyPart driver with MediaPickerField

Work Item: 18677

--HG--
branch : 1.4.x
This commit is contained in:
jao28
2012-05-10 10:53:18 -07:00
parent 9542bf47d0
commit 1b5c3f65e5

View File

@@ -120,10 +120,16 @@ namespace Orchard.Core.Common.Drivers {
private void Add(string segment) {
if (string.IsNullOrEmpty(segment))
return;
if (string.IsNullOrEmpty(_path))
if (string.IsNullOrEmpty(_path)) {
_path = segment;
else
}
else if (segment.StartsWith("/")) {
_path = _path + segment;
}
else {
_path = _path + "/" + segment;
}
}
}
}