[robotInterface] Fix possible bug when merging groups

Thanks: Mirko Ferrati <mirko.ferrati@gmail.com>