From 84c601bc13551296e7897e779c6711ba3be79236 Mon Sep 17 00:00:00 2001 From: Yash Baheti <34238132+yashbth@users.noreply.github.com> Date: Mon, 12 Mar 2018 22:06:16 +0530 Subject: [PATCH] Fixes tag controller "suggested tags" action (#2477) issue #2458 --- app/controllers/tag_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/tag_controller.rb b/app/controllers/tag_controller.rb index 24c45313b9..bbde1a2cdb 100644 --- a/app/controllers/tag_controller.rb +++ b/app/controllers/tag_controller.rb @@ -338,7 +338,7 @@ def delete end def suggested - if params[:id].length > 2 + if !params[:id].empty? && params[:id].length > 2 @suggestions = [] # filtering out tag spam by requiring tags attached to a published node Tag.where('name LIKE ?', '%' + params[:id] + '%')