updating code in search view