From 2b347bb7e62caf926683b3fb89407ecfb70d82a8 Mon Sep 17 00:00:00 2001 From: Guillaume Dott Date: Wed, 18 Nov 2015 12:33:53 +0100 Subject: [PATCH] Correct bug with search link when no movies are found --- lib/librarix/filter.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librarix/filter.rb b/lib/librarix/filter.rb index 71538eb..6a65743 100644 --- a/lib/librarix/filter.rb +++ b/lib/librarix/filter.rb @@ -72,7 +72,7 @@ module Librarix end def maybe_search? - movies.empty? && params.key?('title') + movies.all? { |k,v| v.empty? } && params.key?('title') end end end