Skip to content

Commit

Permalink
Merge pull request #12 from zetamatta/master
Browse files Browse the repository at this point in the history
Fixed `<`,`>` and `&` were printed `&lt;`,`&gt;` or `&amp;`
  • Loading branch information
mattn committed Feb 3, 2017
2 parents 7e75544 + 2bae973 commit 1dc6c32
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions twty.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"encoding/json"
"flag"
"fmt"
"html"
"io"
"io/ioutil"
"log"
Expand Down Expand Up @@ -246,7 +247,7 @@ func showTweets(tweets []Tweet, verbose bool) {
color.Set(color.FgHiRed)
fmt.Println(user + ": " + name)
color.Set(color.Reset)
fmt.Println(" " + text)
fmt.Println(" " + html.UnescapeString(text))
fmt.Println(" " + tweets[i].Identifier)
fmt.Println(" " + tweets[i].CreatedAt)
fmt.Println()
Expand All @@ -259,7 +260,7 @@ func showTweets(tweets []Tweet, verbose bool) {
fmt.Print(user)
color.Set(color.Reset)
fmt.Print(": ")
fmt.Println(text)
fmt.Println(html.UnescapeString(text))
}
}
}
Expand Down

0 comments on commit 1dc6c32

Please sign in to comment.