Fixed a bug when using overlay with groups consisting of only one node.