Skip to content

Commit 60a44d7

Browse files
committed
fix: dynamic debug configs sometimes having the wrong type
I added logic to rename the dynamic type to the "preferred" type (such as from pwa-node to node), but didn't take into account that sometimes the config providers return a different type to their main type. For npm scripts, for example, they return a `node-terminal` type instead of `pwa-node`. Changing the type to `node` resulted in broken configs.
1 parent 87fe3ca commit 60a44d7

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ui/configuration/baseConfigurationProvider.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ export abstract class BaseConfigurationProvider<T extends AnyLaunchConfiguration
4444
const preferredType = preferredDebugTypes.get(this.type);
4545
if (preferredType) {
4646
for (const config of configs) {
47-
config.type = preferredType as T['type'];
47+
if (config.type === this.type) {
48+
config.type = preferredType as T['type'];
49+
}
4850
}
4951
}
5052

0 commit comments

Comments
 (0)