Deprecated: Assigning the return value of new by reference is deprecated in /home/bluestat/public_html/source/index.php on line 477
armadillo - Commitdiff - ViewGit - Blue Static

Trim the show name

Robert Sesek [2011-04-16 21:17]
Trim the show name
Filename
src/tv_rename.go
diff --git a/src/tv_rename.go b/src/tv_rename.go
index a083b66..f07fc04 100644
--- a/src/tv_rename.go
+++ b/src/tv_rename.go
@@ -171,7 +171,7 @@ func parseResponse(response *http.Response) *fullEpisodeInfo {
     }
     switch parts[0] {
       case "Show Name":
-        info.episode.showName = parts[1]
+        info.episode.showName = strings.TrimSpace(parts[1])
       case "Episode Info":
         // Split the line, which is of the form: |SxE^Name^AirDate|.
         parts = strings.Split(parts[1], "^", 3)