search.js: add missing "var"