mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Replacing some left over hard coded content type strings with their *Driver.ContentType.Name references. Fixing for "blogpost", "comment", " page", and "user"
This commit is contained in:
@@ -7,6 +7,7 @@ using Orchard.Data;
|
||||
using Orchard.Logging;
|
||||
using Orchard.ContentManagement;
|
||||
using Orchard.Security;
|
||||
using Orchard.Users.Controllers;
|
||||
using Orchard.Users.Models;
|
||||
|
||||
namespace Orchard.Users.Services {
|
||||
@@ -30,8 +31,9 @@ namespace Orchard.Users.Services {
|
||||
|
||||
public IUser CreateUser(CreateUserParams createUserParams) {
|
||||
Logger.Information("CreateUser {0} {1}", createUserParams.Username, createUserParams.Email);
|
||||
|
||||
return _contentManager.Create<User>("user", init => {
|
||||
|
||||
return _contentManager.Create<User>(UserDriver.ContentType.Name, init =>
|
||||
{
|
||||
init.Record.UserName = createUserParams.Username;
|
||||
init.Record.Email = createUserParams.Email;
|
||||
SetPassword(init.Record, createUserParams.Password);
|
||||
|
Reference in New Issue
Block a user