We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7803ee1 commit 9b886c8Copy full SHA for 9b886c8
packages/cli-repl/src/mongosh-repl.ts
@@ -516,7 +516,15 @@ class MongoshNodeRepl implements EvaluationListener {
516
// the multiline input are replaced at this point.
517
const newHistoryEntry = makeMultilineJSIntoSingleLine(ev.input);
518
if (newHistoryEntry.length > 0) {
519
- originalHistory.unshift(newHistoryEntry);
+ const newLines = [newHistoryEntry];
520
+ changeHistory(
521
+ newLines,
522
+ this.redactHistory === 'remove-redact'
523
+ ? 'redact-sensitive-data'
524
+ : 'keep-sensitive-data'
525
+ );
526
+
527
+ originalHistory.unshift(...newLines);
528
}
529
history.splice(0, history.length, ...originalHistory);
530
originalHistory = null;
0 commit comments