original_string: protected function _checkReturnURI($sourceSurveyId, \Gems_Tracker_Survey $survey, array &$messages)
      {
          $lsSurvLang = $this->_getSurveyLanguagesTableName();
          $sql = 'SELECT surveyls_language FROM ' . $lsSurvLang . ' WHERE surveyls_survey_id = ?';
  
          $lsDb = $this->getSourceDatabase();
  
          $languages = $lsDb->fetchAll($sql, array($sourceSurveyId));
          $langChanges = 0;
          foreach ($languages as $language)
          {
              $langChanges = $langChanges + $lsDb->update(
                  $lsSurvLang,
                  array(
                      'surveyls_urldescription' => $this->_getReturnURIDescription($language['surveyls_language'])
                      ),
                  array(
                      'surveyls_survey_id = ?' => $sourceSurveyId,
                      'surveyls_language = ?'  => $language
                      )
                  );
          }
  
          if ($langChanges > 0) {
              $messages[] = sprintf($this->_('The description of the exit url description was changed for %s languages in survey \'%s\'.'), $langChanges, $survey->getName());
          }
      }
code: protected function _checkReturnURI($sourceSurveyId, \Gems_Tracker_Survey $survey, array &$messages)
      {
          $lsSurvLang = $this->_getSurveyLanguagesTableName();
          $sql = 'SELECT surveyls_language FROM ' . $lsSurvLang . ' WHERE surveyls_survey_id = ?';
  
          $lsDb = $this->getSourceDatabase();
  
          $languages = $lsDb->fetchAll($sql, array($sourceSurveyId));
          $langChanges = 0;
          foreach ($languages as $language)
          {
              $langChanges = $langChanges + $lsDb->update(
                  $lsSurvLang,
                  array(
                      'surveyls_urldescription' => $this->_getReturnURIDescription($language['surveyls_language'])
                      ),
                  array(
                      'surveyls_survey_id = ?' => $sourceSurveyId,
                      'surveyls_language = ?'  => $language
                      )
                  );
          }
  
          if ($langChanges > 0) {
              $messages[] = sprintf($this->_('The description of the exit url description was changed for %s languages in survey \'%s\'.'), $langChanges, $survey->getName());
          }
      }
code_tokens: protected function _checkReturnURI ( $ sourceSurveyId , \ Gems_Tracker_Survey $ survey , array & $ messages ) { $ lsSurvLang = $ this -> _getSurveyLanguagesTableName ( ) ; $ sql = 'SELECT surveyls_language FROM ' . $ lsSurvLang . ' WHERE surveyls_survey_id = ?' ; $ lsDb = $ this -> getSourceDatabase ( ) ; $ languages = $ lsDb -> fetchAll ( $ sql , array ( $ sourceSurveyId ) ) ; $ langChanges = 0 ; foreach ( $ languages as $ language ) { $ langChanges = $ langChanges + $ lsDb -> update ( $ lsSurvLang , array ( 'surveyls_urldescription' => $ this -> _getReturnURIDescription ( $ language [ 'surveyls_language' ] ) ) , array ( 'surveyls_survey_id = ?' => $ sourceSurveyId , 'surveyls_language = ?' => $ language ) ) ; } if ( $ langChanges > 0 ) { $ messages [ ] = sprintf ( $ this -> _ ( 'The description of the exit url description was changed for %s languages in survey \'%s\'.' ) , $ langChanges , $ survey -> getName ( ) ) ; } }
docstring: Checks the return URI in LimeSurvey and sets it to the correct one when needed
  
  @see checkSurvey()
  
  @param string $sourceSurveyId
  @param \Gems_Tracker_Survey $survey
  @param array $messages
docstring_tokens: Checks the return URI in LimeSurvey and sets it to the correct one when needed