From 5a21e5a3cfe7e8f02a77be53da56eb21389e5f65 Mon Sep 17 00:00:00 2001 From: Jan Philipp Timme Date: Mon, 31 Dec 2018 17:20:48 +0100 Subject: [PATCH] Fix missing symbol in tabwriter view --- main.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/main.go b/main.go index 8542e8d..6ad7e27 100644 --- a/main.go +++ b/main.go @@ -24,7 +24,6 @@ func main() { if settings["interactive"] == "true" { interactiveShell() } - fmt.Printf("I am done.\n") } func parseArguments() { @@ -69,7 +68,7 @@ func printQueueEntries(queue parser.MailQ, writer io.Writer) { tabWriter := tabwriter.NewWriter(writer, 2, 2, 1, ' ', tabwriter.TabIndent) fmt.Fprintf(tabWriter, "| %s\t| %s\t| %s\t| %s\t| %s\t| %s\t| %s\t| %s\t| \n", "Date", "Id", "Status", "Size", "Sender", "#", "First Recipient", "Reason") for _, entry := range queue.Entries { - _, writeError := fmt.Fprintf(tabWriter, "| %s\t| %s\t| %s\t| %d\t| %s\t| {%d}\t| %s\t| %s\t \n", entry.Date.Format(parser.SortableDateFormat), entry.Id, entry.Status, entry.Size, entry.Sender, len(entry.Recipients), entry.Recipients[0], entry.Reason) + _, writeError := fmt.Fprintf(tabWriter, "| %s\t| %s\t| %s\t| %d\t| %s\t| {%d}\t| %s\t| %s\t| \n", entry.Date.Format(parser.SortableDateFormat), entry.Id, entry.Status, entry.Size, entry.Sender, len(entry.Recipients), entry.Recipients[0], entry.Reason) if writeError != nil { // A writeError is expected once the reader was closed // This happens when the pager application got terminated