diff --git a/src/commands/schema/diff.ts b/src/commands/schema/diff.ts index fce1ccb4..9cf87829 100644 --- a/src/commands/schema/diff.ts +++ b/src/commands/schema/diff.ts @@ -97,16 +97,14 @@ export default class DiffSchemaCommand extends SchemaCommand { this.log( `Differences from the ${bold()}remote${reset()} schema to the ${bold()}local${reset()} schema:` ); + } else if (source === "active") { + this.log( + `Differences from the ${bold()}remote, active${reset()} schema to the ${bold()}local${reset()} schema:` + ); } else { - if (source === "active") { - this.log( - `Differences from the ${bold()}remote, active${reset()} schema to the ${bold()}local${reset()} schema:` - ); - } else { - this.log( - `Differences from the ${bold()}remote, staged${reset()} schema to the ${bold()}local${reset()} schema:` - ); - } + this.log( + `Differences from the ${bold()}remote, staged${reset()} schema to the ${bold()}local${reset()} schema:` + ); } this.log(json.diff ? json.diff : "No schema differences"); } diff --git a/src/commands/schema/pull.ts b/src/commands/schema/pull.ts index 42884146..ddbd5b10 100644 --- a/src/commands/schema/pull.ts +++ b/src/commands/schema/pull.ts @@ -99,18 +99,18 @@ export default class PullSchemaCommand extends SchemaCommand { console.log(`overwrite: ${overwrite}`); } - if (this.flags?.delete) { - // Delete extra .fsl files. - for (const deleteme of deletes) { - fs.unlinkSync(path.join(this.dir, deleteme)); - } - } - const confirmed = await confirm({ message: "Accept the changes?", default: false, }); if (confirmed) { + if (this.flags?.delete) { + // Delete extra .fsl files. + for (const deleteme of deletes) { + fs.unlinkSync(path.join(this.dir, deleteme)); + } + } + for (const filename of filenames) { const fileres = await fetch( new URL(`/schema/1/files/${encodeURIComponent(filename)}`, url),