Skip to content
This repository was archived by the owner on Apr 4, 2025. It is now read-only.

Commit f12f82b

Browse files
committed
fix(@schematics/angular): update script now migrate warnings settings
1 parent 8db7b64 commit f12f82b

File tree

1 file changed

+14
-0
lines changed
  • packages/schematics/angular/migrations/update-6

1 file changed

+14
-0
lines changed

packages/schematics/angular/migrations/update-6/index.ts

+14
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,20 @@ function extractCliConfig(config: CliConfig): JsonObject | null {
105105
if (config.packageManager && config.packageManager !== 'default') {
106106
newConfig['packageManager'] = config.packageManager;
107107
}
108+
if (config.warnings) {
109+
if (config.warnings.versionMismatch !== undefined) {
110+
newConfig.warnings = {
111+
...((newConfig.warnings as JsonObject | null) || {}),
112+
...{ versionMismatch: config.warnings.versionMismatch },
113+
};
114+
}
115+
if (config.warnings.typescriptMismatch !== undefined) {
116+
newConfig.warnings = {
117+
...((newConfig.warnings as JsonObject | null) || {}),
118+
...{ typescriptMismatch: config.warnings.typescriptMismatch },
119+
};
120+
}
121+
}
108122

109123
return Object.getOwnPropertyNames(newConfig).length == 0 ? null : newConfig;
110124
}

0 commit comments

Comments
 (0)