Bugfix: Fix script to work when searching from homepage