Fixed search and cleaned up some minor issues