broke search functionality out into separate plugin file