Fix the use of group in the closure