Fix indentation.
This commit is contained in:
parent
a8340dfbbe
commit
774e2a1517
|
@ -19,19 +19,18 @@
|
||||||
* @params reqModuleName Module name e.g. (ep_etherpad-lite/static/js/plugins)
|
* @params reqModuleName Module name e.g. (ep_etherpad-lite/static/js/plugins)
|
||||||
*/
|
*/
|
||||||
exports.getRequirementFromParent = function(requireDefObj, reqModuleName) {
|
exports.getRequirementFromParent = function(requireDefObj, reqModuleName) {
|
||||||
requireDefObj.define(reqModuleName, function(require, exports, module) {
|
requireDefObj.define(reqModuleName, function(require, exports, module) {
|
||||||
var t = parent;
|
var t = parent;
|
||||||
var max = 0; // make sure I don't go up more than 10 times
|
var max = 0; // make sure I don't go up more than 10 times
|
||||||
while (typeof(t) != "undefined") {
|
while (typeof(t) != "undefined") {
|
||||||
max++;
|
max++;
|
||||||
if (max==10)
|
if (max==10)
|
||||||
break;
|
break;
|
||||||
if (typeof(t.require) != "undefined") {
|
if (typeof(t.require) != "undefined") {
|
||||||
module.exports = t.require(reqModuleName);
|
module.exports = t.require(reqModuleName);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
t = t.parent;
|
t = t.parent;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue