summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/gorilla/websocket/examples/filewatch
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/gorilla/websocket/examples/filewatch')
-rw-r--r--vendor/github.com/gorilla/websocket/examples/filewatch/main.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/vendor/github.com/gorilla/websocket/examples/filewatch/main.go b/vendor/github.com/gorilla/websocket/examples/filewatch/main.go
index a2c7b85f..f5f9da5c 100644
--- a/vendor/github.com/gorilla/websocket/examples/filewatch/main.go
+++ b/vendor/github.com/gorilla/websocket/examples/filewatch/main.go
@@ -6,12 +6,12 @@ package main
import (
"flag"
+ "html/template"
"io/ioutil"
"log"
"net/http"
"os"
"strconv"
- "text/template"
"time"
"github.com/gorilla/websocket"
@@ -120,7 +120,7 @@ func serveWs(w http.ResponseWriter, r *http.Request) {
}
var lastMod time.Time
- if n, err := strconv.ParseInt(r.FormValue("lastMod"), 16, 64); err != nil {
+ if n, err := strconv.ParseInt(r.FormValue("lastMod"), 16, 64); err == nil {
lastMod = time.Unix(0, n)
}