#17111: Correcting fix. Fixing specflows.

--HG--
branch : dev
This commit is contained in:
andrerod
2011-02-09 00:07:12 -08:00
parent 4eff84d2f7
commit 5d55e95506
3 changed files with 17 additions and 2 deletions

View File

@@ -47,7 +47,7 @@ namespace Orchard.Core.Routable.Services {
}
public void FillSlugFromTitle<TModel>(TModel model) where TModel : IRoutableAspect {
if (!string.IsNullOrEmpty(model.Slug) || string.IsNullOrEmpty(model.Title))
if ((model.Slug != null && !string.IsNullOrEmpty(model.Slug.Trim())) || string.IsNullOrEmpty(model.Title))
return;
FillSlugContext slugContext = new FillSlugContext(model.Title);

View File

@@ -10,7 +10,6 @@ namespace Orchard.Core.Routable.ViewModels {
[StringLength(1024)]
public string Title { get; set; }
[StringLength(1024)]
[Required(AllowEmptyStrings = false)]
public string Slug { get; set; }
public int? ContainerId { get; set; }
public bool PromoteToHomePage { get; set; }