Skip to content

Commit

Permalink
fix: debug configuration provider replaces different provider (eclips…
Browse files Browse the repository at this point in the history
…e-theia#13196)

Signed-off-by: arekzaluski <arkadiusz.zaluski@arm.com>
  • Loading branch information
arekzaluski committed Dec 22, 2023
1 parent 248358d commit df72e6a
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,13 @@ export class PluginDebugService implements DebugService {
}, 100);

registerDebugConfigurationProvider(provider: PluginDebugConfigurationProvider): Disposable {
if (this.configurationProviders.has(provider.handle)) {
const configuration = this.configurationProviders.get(provider.handle);
if (configuration && configuration.type !== provider.type) {
console.warn(`Different debug configuration provider with type '${configuration.type}' already registered.`);
provider.handle = this.configurationProviders.size;
}
}
const handle = provider.handle;
this.configurationProviders.set(handle, provider);
this.fireOnDidConfigurationProvidersChanged();
Expand Down

0 comments on commit df72e6a

Please sign in to comment.