From 74a113646d3c3c5ba88f7fe58acbb77404759ad5 Mon Sep 17 00:00:00 2001 From: Shannon Date: Fri, 12 Sep 2014 12:52:32 +1000 Subject: [PATCH] typeo and fixes a return value --- src/Umbraco.Core/ApplicationEventHandler.cs | 2 +- .../common/services/localization.service.js | 21 ++++++++++--------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/src/Umbraco.Core/ApplicationEventHandler.cs b/src/Umbraco.Core/ApplicationEventHandler.cs index c84826cdff..8d97baac95 100644 --- a/src/Umbraco.Core/ApplicationEventHandler.cs +++ b/src/Umbraco.Core/ApplicationEventHandler.cs @@ -47,7 +47,7 @@ namespace Umbraco.Core } /// - /// OVerridable method to execute when All resolvers have been initialized but resolution is not frozen so they can be modified in this method + /// Overridable method to execute when All resolvers have been initialized but resolution is not frozen so they can be modified in this method /// /// /// diff --git a/src/Umbraco.Web.UI.Client/src/common/services/localization.service.js b/src/Umbraco.Web.UI.Client/src/common/services/localization.service.js index 6a46da27f2..0cdb600f1e 100644 --- a/src/Umbraco.Web.UI.Client/src/common/services/localization.service.js +++ b/src/Umbraco.Web.UI.Client/src/common/services/localization.service.js @@ -49,18 +49,19 @@ angular.module('umbraco.services') //helper to tokenize and compile a localization string tokenize: function(value,scope) { - if(value){ - var localizer = value.split(':'); - var retval = {tokens: undefined, key: localizer[0].substring(0)}; - if(localizer.length > 1){ - retval.tokens = localizer[1].split(','); - for (var x = 0; x < retval.tokens.length; x++) { - retval.tokens[x] = scope.$eval(retval.tokens[x]); - } + if (value) { + var localizer = value.split(':'); + var retval = { tokens: undefined, key: localizer[0].substring(0) }; + if (localizer.length > 1) { + retval.tokens = localizer[1].split(','); + for (var x = 0; x < retval.tokens.length; x++) { + retval.tokens[x] = scope.$eval(retval.tokens[x]); } - - return retval; } + + return retval; + } + return value; }, // checks the dictionary for a localized resource string