From 253ea8113bd3afc210e78a56b57e2371c8695dd8 Mon Sep 17 00:00:00 2001
From: Omar Roth <omarroth@hotmail.com>
Date: Sat, 24 Mar 2018 22:39:07 -0500
Subject: [PATCH] Minor fix for filters and search

---
 src/invidious.cr     | 2 +-
 src/views/search.ecr | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/invidious.cr b/src/invidious.cr
index c9486e63..8d3d1894 100644
--- a/src/invidious.cr
+++ b/src/invidious.cr
@@ -164,7 +164,7 @@ spawn do
   end
 end
 
-before_all do |env|
+before_get do |env|
   if env.request.cookies["SID"]?
     env.set "authorized", true
   else
diff --git a/src/views/search.ecr b/src/views/search.ecr
index 462abed4..9f96dd3f 100644
--- a/src/views/search.ecr
+++ b/src/views/search.ecr
@@ -9,7 +9,7 @@
         <div style="overflow-wrap:break-word; word-wrap:break-word;" class="h-box">
             <a style="width:100%;" href="<%= video["link"] %>">
                 <img style="width:100%;" src="<%= video["thumbnail"] %>"/>
-                <%= video["title"] %>
+                <p><%= video["title"] %></p>
             </a>
             <p>
                 <b><a style="width:100%;" href="<%= video["author_url"]%>"><%= video["author"] %></a></b>