diff --git a/src/internal/movies/handlers.go b/src/internal/movies/handlers.go index 0e66697..c701312 100644 --- a/src/internal/movies/handlers.go +++ b/src/internal/movies/handlers.go @@ -96,7 +96,8 @@ func FromPolochon(env *web.Env, w http.ResponseWriter, r *http.Request) error { env.Log.Info(movies) - return nil + web.SetData(r, "movies", movies) + return env.Rends(w, r, "movies/library") } func ExplorePopular(env *web.Env, w http.ResponseWriter, r *http.Request) error { diff --git a/src/templates/movies/library.tmpl b/src/templates/movies/library.tmpl index d31395f..7a21482 100644 --- a/src/templates/movies/library.tmpl +++ b/src/templates/movies/library.tmpl @@ -1,6 +1,10 @@ {{ if $.Data.error }} + {{ if eq $.Data.error "Invalid address"}} -
+ + {{ .Runtime }} min +
+ ++ + {{ .Rating }} ({{ .Votes }} counts) +
+ +{{ .Plot }}
+