diff --git a/modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Comments/CommentAppService.cs b/modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Comments/CommentAppService.cs index cf34edb434..8ceb20427e 100644 --- a/modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Comments/CommentAppService.cs +++ b/modules/blogging/src/Volo.Blogging.Application/Volo/Blogging/Comments/CommentAppService.cs @@ -86,6 +86,8 @@ namespace Volo.Blogging.Comments comment = await _commentRepository.InsertAsync(comment); + await CurrentUnitOfWork.SaveChangesAsync(); + return ObjectMapper.Map(comment); } diff --git a/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/Detail.cshtml b/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/Detail.cshtml index 2efd9b1d22..bf8c121688 100644 --- a/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/Detail.cshtml +++ b/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/Detail.cshtml @@ -151,7 +151,7 @@ } else { - @L["LeaveComment"] + @L["LeaveComment"] } @@ -342,7 +342,7 @@ } else { - @L["LeaveComment"] + @L["LeaveComment"] } diff --git a/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/new.js b/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/new.js index 3edacd49b5..f5686e64e6 100644 --- a/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/new.js +++ b/modules/blogging/src/Volo.Blogging.Web/Pages/Blogs/Posts/new.js @@ -118,6 +118,9 @@ $titleLengthWarning.hide(); } + title = title.replace(' &', ' '); + title = title.replace('& ', ' '); + title = title.replace('&', ''); title = title.replace(' ', '-'); title = title.replace(new RegExp(' ', 'g'), '-'); reflectedChange = true;