fix bug triggered by using search and public params together