[Pkg-javascript-commits] [dojo] 69/149: Fixes #18497, Reverse the order of locales merging during layer preload.
David Prévot
taffit at moszumanska.debian.org
Sat Feb 27 03:13:48 UTC 2016
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository dojo.
commit f6b42a1ab3a65053fed2935fdfef93fe197dd323
Author: Clément Mathieu <clement.mathieu at outlook.com>
Date: Sun Jul 12 06:52:08 2015 -0700
Fixes #18497, Reverse the order of locales merging during layer preload.
---
i18n.js | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/i18n.js b/i18n.js
index aa3fdbb..2521927 100644
--- a/i18n.js
+++ b/i18n.js
@@ -419,7 +419,10 @@ define(["./_base/kernel", "require", "./has", "./_base/array", "./_base/config",
if(requiredBundles.length){
preloadingAddLock();
contextRequire(requiredBundles, function(){
- for(var i = 0; i < requiredBundles.length; i++){
+ // requiredBundles was constructed by forEachLocale so it contains locales from
+ // less specific to most specific.
+ // the loop starts with the most specific locale, the last one.
+ for(var i = requiredBundles.length - 1; i >= 0 ; i--){
bundle = lang.mixin(lang.clone(bundle), arguments[i]);
cache[cacheIds[i]] = bundle;
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/dojo.git
More information about the Pkg-javascript-commits
mailing list