updated search.js