fix getAppName sometimes reports "phpgwapi" from this.appName causing eg. attachment icon in filemanager to come from old phpgwapi directory

This commit is contained in:
ralf 2022-08-02 14:52:20 +02:00
parent 5d1ccb55a0
commit f699c36a47

View File

@ -512,17 +512,11 @@
* Returns the current application name. The current application
* name equals the name, which was given when calling the egw
* function. If the getAppName function is called on the global
* instance, 'etemplate' is returned.
* instance, 'api' is returned.
*/
getAppName: function() {
// Return the default application name if this function is
// called on the global egw instance.
if (!this.appName) {
return 'etemplate';
}
// Otherwise return the correct application name.
return this.appName;
return this.app_name() || this.appName || 'api';
},
/**
@ -716,5 +710,4 @@
// Publish the egw object
this['egw'] = egw;
}
}).call(window);
}).call(window);