From 4ef16ef92d1791328dc74f3a0700eff4f3761179 Mon Sep 17 00:00:00 2001 From: rolux Date: Fri, 26 Oct 2012 18:16:44 +0200 Subject: [PATCH] when computing sort values, only strip non-word characters from the beginning of the value if the result is not an empty string --- source/Ox/js/Array.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/Ox/js/Array.js b/source/Ox/js/Array.js index 2eb35de2..d3a3c86a 100644 --- a/source/Ox/js/Array.js +++ b/source/Ox/js/Array.js @@ -598,7 +598,7 @@ Ox.range = function() { var getSortValue = Ox.cache(function getSortValue(value) { var sortValue = value; function trim(value) { - return value.replace(/^\W+/, ''); + return value.replace(/^\W+(?=\w)/, ''); } if ( Ox.isEmpty(value)