From 787e10bbe1ee199376df9ba31161d27837f65656 Mon Sep 17 00:00:00 2001 From: Shannon Date: Tue, 25 Nov 2014 18:02:17 +1100 Subject: [PATCH] ensures the templates are sorted by name --- src/Umbraco.Core/Services/FileService.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Core/Services/FileService.cs b/src/Umbraco.Core/Services/FileService.cs index 9709448cc3..48fbefa1ab 100644 --- a/src/Umbraco.Core/Services/FileService.cs +++ b/src/Umbraco.Core/Services/FileService.cs @@ -247,7 +247,7 @@ namespace Umbraco.Core.Services { using (var repository = _repositoryFactory.CreateTemplateRepository(_dataUowProvider.GetUnitOfWork())) { - return repository.GetAll(aliases); + return repository.GetAll(aliases).OrderBy(x => x.Name); } } @@ -259,7 +259,7 @@ namespace Umbraco.Core.Services { using (var repository = _repositoryFactory.CreateTemplateRepository(_dataUowProvider.GetUnitOfWork())) { - return repository.GetChildren(masterTemplateId); + return repository.GetChildren(masterTemplateId).OrderBy(x => x.Name); } }