From 9c14fb6c02542480e435456a0631d29749b4db83 Mon Sep 17 00:00:00 2001 From: Shaarad Dalvi <60266155+shaaraddalvi@users.noreply.github.com> Date: Sun, 24 May 2020 23:07:08 +0530 Subject: [PATCH] Show error when trying to sort by invalid column (#1880) * Show error when trying to sort by invalid column * Added test for changes * Addressed comments, updated test * Removed unnecessary mutable keyword * Changed split-column to solt column after rebase from upstream --- crates/nu-cli/src/commands/sort_by.rs | 12 ++++++++++++ crates/nu-cli/tests/commands/sort_by.rs | 23 +++++++++++++++++++++++ 2 files changed, 35 insertions(+) diff --git a/crates/nu-cli/src/commands/sort_by.rs b/crates/nu-cli/src/commands/sort_by.rs index 7a810679a..d5f7a707a 100644 --- a/crates/nu-cli/src/commands/sort_by.rs +++ b/crates/nu-cli/src/commands/sort_by.rs @@ -69,6 +69,18 @@ fn sort_by(args: CommandArgs, registry: &CommandRegistry) -> Result