Fixes U4-1443 by ensuring that the User Id is passed along to the Save method.

This commit is contained in:
Morten Christensen
2013-01-14 13:18:29 -01:00
parent 0466a8ce13
commit 4ec192d2dd

View File

@@ -345,7 +345,7 @@ namespace umbraco.cms.businesslogic.web
//Create a new IContent object based on the passed in DocumentType's alias, set the name and save it
IContent content = ApplicationContext.Current.Services.ContentService.CreateContent(ParentId, dct.Alias, u.Id);
content.Name = Name;
ApplicationContext.Current.Services.ContentService.Save(content);
ApplicationContext.Current.Services.ContentService.Save(content, u.Id);
//read the whole object from the db
Document d = new Document(content);
@@ -949,7 +949,9 @@ namespace umbraco.cms.businesslogic.web
if (!e.Cancel)
{
ApplicationContext.Current.Services.ContentService.Save(Content);
var current = User.GetCurrent();
int userId = current == null ? 0 : current.Id;
ApplicationContext.Current.Services.ContentService.Save(Content, userId);
base.Save();
// update preview xml