mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Avoid .bind with .loadOnClusterRenderer
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
This commit is contained in:
parent
95a5307fcd
commit
09a4da6b28
@ -364,7 +364,7 @@ export class ExtensionLoader {
|
||||
});
|
||||
}
|
||||
|
||||
protected autoInitExtensions(register: (ext: LensExtension) => Promise<Disposer[]>) {
|
||||
protected autoInitExtensions = (register: (ext: LensExtension) => Promise<Disposer[]>) => {
|
||||
// Setup reaction to load extensions on JSON changes
|
||||
reaction(() => this.toJSON(), installedExtensions => this.loadExtensions(installedExtensions, register));
|
||||
|
||||
|
||||
@ -13,11 +13,9 @@ import clusterFrameContextInjectable from "../../../cluster-frame-context/cluste
|
||||
|
||||
const initClusterFrameInjectable = getInjectable({
|
||||
instantiate: (di) => {
|
||||
const extensionLoader = di.inject(extensionLoaderInjectable);
|
||||
|
||||
return initClusterFrame({
|
||||
hostedCluster: di.inject(hostedClusterInjectable),
|
||||
loadExtensions: extensionLoader.loadOnClusterRenderer.bind(extensionLoader),
|
||||
loadExtensions: di.inject(extensionLoaderInjectable).loadOnClusterRenderer,
|
||||
catalogEntityRegistry: di.inject(catalogEntityRegistryInjectable),
|
||||
frameRoutingId: di.inject(frameRoutingIdInjectable),
|
||||
emitEvent: di.inject(appEventBusInjectable).emit,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user