Logic fix and changes to maintain search functionality over time