MDL-68528 js: Normalise core component for template strings
authorAndrew Nicols <andrew@nicols.co.uk>
Sun, 26 Apr 2020 07:57:59 +0000 (15:57 +0800)
committerAndrew Nicols <andrew@nicols.co.uk>
Tue, 19 May 2020 03:40:44 +0000 (11:40 +0800)
lib/amd/build/templates.min.js
lib/amd/build/templates.min.js.map
lib/amd/src/templates.js

index c907e2b..24665b1 100644 (file)
Binary files a/lib/amd/build/templates.min.js and b/lib/amd/build/templates.min.js differ
index 202d4bd..119e917 100644 (file)
Binary files a/lib/amd/build/templates.min.js.map and b/lib/amd/build/templates.min.js.map differ
index db830df..c145173 100644 (file)
@@ -508,6 +508,10 @@ define([
             param = parts.join(',').trim();
         }
 
+        if (!component || component === 'moodle') {
+            component = 'core';
+        }
+
         if (param !== '') {
             // Allow variable expansion in the param part only.
             param = helper(param, context);