Fixes U4-2052 for new mediatypes as well
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Data;
|
||||
using System.Web.Security;
|
||||
using Umbraco.Core;
|
||||
using umbraco.BusinessLogic;
|
||||
using umbraco.DataLayer;
|
||||
using umbraco.BasePages;
|
||||
@@ -41,9 +42,11 @@ namespace umbraco
|
||||
}
|
||||
|
||||
public bool Save()
|
||||
{
|
||||
int id = cms.businesslogic.media.MediaType.MakeNew(BusinessLogic.User.GetUser(_userID), Alias.Replace("'", "''")).Id;
|
||||
m_returnUrl = string.Format("settings/editMediaType.aspx?id={0}", id);
|
||||
{
|
||||
var mediaType = cms.businesslogic.media.MediaType.MakeNew(User.GetUser(_userID), Alias.Replace("'", "''"));
|
||||
mediaType.IconUrl = UmbracoSettings.IconPickerBehaviour == IconPickerBehaviour.HideFileDuplicates ? ".sprTreeFolder" : "folder.gif";
|
||||
|
||||
m_returnUrl = string.Format("settings/editMediaType.aspx?id={0}", mediaType.Id);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user