Fixed iteration bug in search/browse.