fixed selecting type from search
warning fixes