Fixes for a few provider issues plus passing of search_mode variable.