mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-01-19 09:42:29 +08:00
Fixed the image profiler manager returning profile paths even when the image creation has failed (#7901)
This commit is contained in:
committed by
Sébastien Ros
parent
60077743eb
commit
9ea077830b
@@ -131,13 +131,12 @@ namespace Orchard.MediaProcessing.Services {
|
||||
// to handle cross machines concurrency
|
||||
lock (String.Intern(path)) {
|
||||
using (var image = GetImage(path)) {
|
||||
if (image == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var filterContext = new FilterContext { Media = image, FilePath = _storageProvider.Combine("_Profiles", FormatProfilePath(profileName, System.Web.HttpUtility.UrlDecode(path))) };
|
||||
|
||||
if (image == null) {
|
||||
return filterContext.FilePath;
|
||||
}
|
||||
|
||||
var tokens = new Dictionary<string, object>();
|
||||
// if a content item is provided, use it while tokenizing
|
||||
if (contentItem != null) {
|
||||
|
||||
Reference in New Issue
Block a user