Add search param to getPosts