diff options
Diffstat (limited to 'modules/g2_import')
| -rw-r--r-- | modules/g2_import/helpers/g2_import.php | 8 | 
1 files changed, 7 insertions, 1 deletions
diff --git a/modules/g2_import/helpers/g2_import.php b/modules/g2_import/helpers/g2_import.php index 7eb7724f..00fa6f47 100644 --- a/modules/g2_import/helpers/g2_import.php +++ b/modules/g2_import/helpers/g2_import.php @@ -141,7 +141,13 @@ class g2_import_Core {      $g2_group = g2(GalleryCoreApi::loadEntitiesById($g2_group_id));      switch ($g2_group->getGroupType()) {      case GROUP_NORMAL: -      $group = group::create($g2_group->getGroupName()); +      try { +        $group = group::create($g2_group->getGroupName()); +      } catch (Exception $e) { +        // @todo For now we assume this is a "duplicate group" exception +        $group = group::lookup_by_name($g2_group->getGroupname()); +      } +        break;      case GROUP_ALL_USERS:  | 
