fix(appdata): Fix iteration over overwriteObject in AppData and update configuration for dependency and path handling

This commit is contained in:
2025-08-15 12:12:26 +00:00
parent 5e0edecf18
commit 62e61168a0
25 changed files with 5821 additions and 2835 deletions

View File

@@ -27,7 +27,10 @@ export class Npmextra {
/**
* merges the supplied options with the ones from npmextra.json
*/
dataFor<IToolConfig>(toolnameArg: string, defaultOptionsArg: any): IToolConfig {
dataFor<IToolConfig>(
toolnameArg: string,
defaultOptionsArg: any,
): IToolConfig {
let npmextraToolOptions;
if (this.npmextraJsonData[toolnameArg]) {
npmextraToolOptions = this.npmextraJsonData[toolnameArg];
@@ -45,7 +48,9 @@ export class Npmextra {
* checks if the JSON exists
*/
private checkNpmextraJsonExists() {
this.npmextraJsonExists = plugins.smartfile.fs.fileExistsSync(this.lookupPath);
this.npmextraJsonExists = plugins.smartfile.fs.fileExistsSync(
this.lookupPath,
);
}
/**
@@ -64,7 +69,9 @@ export class Npmextra {
*/
private checkNpmextraJsonData() {
if (this.npmextraJsonExists) {
this.npmextraJsonData = plugins.smartfile.fs.toObjectSync(this.lookupPath);
this.npmextraJsonData = plugins.smartfile.fs.toObjectSync(
this.lookupPath,
);
} else {
this.npmextraJsonData = {};
}