mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-26 03:40:56 +08:00
#18863: Orchard.Media : MetaWeblogNewMediaObject doesn't delete a file without directory name
--HG-- branch : 1.x
This commit is contained in:
@@ -73,7 +73,7 @@ namespace Orchard.Media.Services {
|
|||||||
try {
|
try {
|
||||||
// delete the file if it already exists, e.g. an updated image in a blog post
|
// delete the file if it already exists, e.g. an updated image in a blog post
|
||||||
// it's safe to delete the file as each content item gets a specific folder
|
// it's safe to delete the file as each content item gets a specific folder
|
||||||
_mediaService.DeleteFile(Path.GetDirectoryName(name), Path.GetFileName(name));
|
_mediaService.DeleteFile(directoryName, Path.GetFileName(name));
|
||||||
}
|
}
|
||||||
catch {
|
catch {
|
||||||
// current way to delete a file if it exists
|
// current way to delete a file if it exists
|
||||||
|
|||||||
Reference in New Issue
Block a user