From dbadf9499e9915d98c2e62bf1ad3647ca5af5a37 Mon Sep 17 00:00:00 2001 From: Jonathan Turner Date: Mon, 9 Dec 2019 08:15:14 +1300 Subject: [PATCH] Fix 1068 --- Cargo.toml | 2 +- crates/nu_plugin_textview/src/main.rs | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 7899bcb61..2d546770f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -128,7 +128,7 @@ pretty_assertions = "0.6.1" [build-dependencies] toml = "0.5.5" -serde = { version = "1.0.102", features = ["derive"] } +serde = { version = "1.0.103", features = ["derive"] } nu-build = { version = "0.1.0", path = "./crates/nu-build" } [lib] diff --git a/crates/nu_plugin_textview/src/main.rs b/crates/nu_plugin_textview/src/main.rs index 6a35fed90..0d0c24abd 100644 --- a/crates/nu_plugin_textview/src/main.rs +++ b/crates/nu_plugin_textview/src/main.rs @@ -32,7 +32,9 @@ impl Plugin for TextView { } fn sink(&mut self, _call_info: CallInfo, input: Vec) { - view_text_value(&input[0]); + if !input.is_empty() { + view_text_value(&input[0]); + } } }