if ($groupsDuplicated > 0) {
     $Fields['PRO_FILENAME'] = $filename;
     $Fields['PRO_PATH'] = $path;
     $Fields['IMPORT_OPTION'] = $option;
     $Fields['OBJ_UID'] = $ObjUid;
     $G_MAIN_MENU = 'processmaker';
     $G_ID_MENU_SELECTED = 'PROCESSES';
     $G_PUBLISH = new Publisher();
     $G_PUBLISH->AddContent('xmlform', 'xmlform', 'processes/processes_ValidatingGroups', '', $Fields, 'processes_ImportExisting');
     G::RenderPage('publish', "blank");
     die;
 }
 //end added code
 //Update the current Process, overwriting all tasks and steps
 if ($option == 1) {
     $oProcess->updateProcessFromData($oData, $path . $filename);
     if (file_exists(PATH_OUTTRUNK . 'compiled' . PATH_SEP . 'xmlform' . PATH_SEP . $sProUid)) {
         $oDirectory = dir(PATH_OUTTRUNK . 'compiled' . PATH_SEP . 'xmlform' . PATH_SEP . $sProUid);
         while ($sObjectName = $oDirectory->read()) {
             if ($sObjectName != '.' && $sObjectName != '..') {
                 unlink(PATH_OUTTRUNK . 'compiled' . PATH_SEP . 'xmlform' . PATH_SEP . $sProUid . PATH_SEP . $sObjectName);
             }
         }
         $oDirectory->close();
     }
     $sNewProUid = $sProUid;
 }
 //Disable current Process and create a new version of the Process
 if ($option == 2) {
     $oProcess->disablePreviousProcesses($sProUid);
     $sNewProUid = $oProcess->getUnusedProcessGUID();