Commented search function