fixes #5489 - don't generate empty search () filters on permissions migration