Skip to content

Commit

Permalink
Update angular2-plugin-factory.ts to handle missing entrypoint
Browse files Browse the repository at this point in the history
Signed-off-by: 1000TurquoisePogs <[email protected]>
  • Loading branch information
1000TurquoisePogs authored Aug 27, 2024
1 parent 7e06e4b commit 2540a79
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,13 @@ class SimpleAngularComponentFactory extends ComponentFactory {
export class Angular2PluginFactory extends PluginFactory {
private readonly logger: ZLUX.ComponentLogger = BaseLogger;
private static getAngularModuleURL(pluginDefinition: MVDHosting.DesktopPluginDefinition): string {
let entryPoint = pluginDefinition.getBasePlugin().getWebEntryPoint() || 'main.js';
return ZoweZLUX.uriBroker.pluginResourceUri(pluginDefinition.getBasePlugin(), entryPoint);
let pluginDefBase = pluginDefinition.getBasePlugin();
let pluginDefAny:any = (pluginDefBase as any);
let entryPoint = 'main.js';
if (pluginDefAny.getWebEntryPoint) {
entryPoint = pluginDefAny.getWebEntryPoint() || 'main.js';
}
return ZoweZLUX.uriBroker.pluginResourceUri(pluginDefBase, entryPoint);
}

private static getAngularComponentsURL(pluginDefinition: MVDHosting.DesktopPluginDefinition): string {
Expand Down

0 comments on commit 2540a79

Please sign in to comment.