working to fix search behavior but its complicated