refactored a little bit, but no result
added trivial search
fixed search in groups