fix not working applyFunc if app.js was not yet loaded (missing return of the Promise)

This commit is contained in:
Ralf Becker 2021-06-15 11:51:10 +02:00
parent e7a3c031b2
commit af3193480c

View File

@ -537,7 +537,7 @@ egw.extend('json', egw.MODULE_WND_LOCAL, function(_app, _wnd)
// check if we need a not yet included app.js object --> include it now and return a Promise
else if (i == 1 && parts[0] == 'app' && typeof app.classes[parts[1]] === 'undefined')
{
this.includeJS('/'+parts[1]+'/js/app.js', undefined, undefined, this.webserverUrl)
return this.includeJS('/'+parts[1]+'/js/app.js', undefined, undefined, this.webserverUrl)
.then(() => this.applyFunc(_func, args, _context));
}
// check if we need a not yet instantiated app.js object --> instantiate it now