Load installed server add-ons
Reviewed By: nikoant Differential Revision: D34300475 fbshipit-source-id: 6bb6c0ab811e28806a0924b3487931bdb0dd2c59
This commit is contained in:
committed by
Facebook GitHub Bot
parent
b4b9c0ab28
commit
8b94186783
@@ -510,16 +510,24 @@ export abstract class BasePluginInstance {
|
||||
protected abstract serverAddOnOwner: string;
|
||||
|
||||
protected startServerAddOn() {
|
||||
const {serverAddOn, name} = this.definition.details;
|
||||
if (serverAddOn) {
|
||||
this.serverAddOnControls.start(name, this.serverAddOnOwner).catch((e) => {
|
||||
console.warn(
|
||||
'Failed to start a server add on',
|
||||
name,
|
||||
const pluginDetails = this.definition.details;
|
||||
if (pluginDetails.serverAddOn) {
|
||||
this.serverAddOnControls
|
||||
.start(
|
||||
pluginDetails.name,
|
||||
pluginDetails.isBundled
|
||||
? {isBundled: true}
|
||||
: {path: pluginDetails.serverAddOnEntry!},
|
||||
this.serverAddOnOwner,
|
||||
e,
|
||||
);
|
||||
});
|
||||
)
|
||||
.catch((e) => {
|
||||
console.warn(
|
||||
'Failed to start a server add on',
|
||||
pluginDetails.name,
|
||||
this.serverAddOnOwner,
|
||||
e,
|
||||
);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user