Move searc options to hash outside of search function