[1.x] Blogs/XmlRpcHandler does not handle Autoroute

Topics: Core
Feb 14, 2012 at 6:33 PM

A quick error I've discovered while trying to update Contrib.RemotePages to orchard 1.4 (using current hg revision 5970). In XmlRpcHandler in Orchard.Blogs/Services, the slug is not handled correctly : I think you should use "DisplayAlias" property instead of "Alias". See my patch below:

@@ -211,7 +211,7 @@
             //AutoroutePart
             dynamic dBlogPost = blogPost;
             if (dBlogPost.AutoroutePart!=null){
-                dBlogPost.AutoroutePart.Alias = slug;
+                dBlogPost.AutoroutePart.DisplayAlias = slug;
             }
 
             _contentManager.Create(blogPost, VersionOptions.Draft);

@@ -294,7 +294,7 @@
             //AutoroutePart
             dynamic dBlogPost = blogPost;
             if (dBlogPost.AutoroutePart != null) {
-                dBlogPost.AutoroutePart.Alias = slug;
+                dBlogPost.AutoroutePart.DisplayAlias = slug;
             }
 
             // try to get the UTC timezone by default

Sorry for not forking/sending a pull request. If you consider it mandatory, please advise me.

Coordinator
Feb 14, 2012 at 7:23 PM

Thanks, I have applied the patch under your name, dear new contributor.