fixed bug for search with controller, minor design fixes