Skip to content

Commit

Permalink
Fixed issue #5184: Unnecessary duplicate query when listing surveys -…
Browse files Browse the repository at this point in the history
… patch by TMSWhite

git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/limesurvey@10138 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
c-schmitz committed May 28, 2011
1 parent 38fb968 commit 493304e
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions index.php
Expand Up @@ -390,6 +390,7 @@
ON ( surveyls_survey_id = a.sid AND surveyls_language = a.language )
WHERE surveyls_survey_id=a.sid
AND surveyls_language=a.language
AND surveyls_language='$baselang'
AND a.active='Y'
AND a.listpublic='Y'
AND ((a.expires >= '".date("Y-m-d H:i")."') OR (a.expires is null))
Expand All @@ -401,12 +402,6 @@
{
while($rows = $result->FetchRow())
{
$result2 = db_execute_assoc("Select surveyls_title from ".db_table_name('surveys_languagesettings')." where surveyls_survey_id={$rows['sid']} and surveyls_language='$baselang'");
if ($result2->RecordCount())
{
$languagedetails=$result2->FetchRow();
$rows['surveyls_title']=$languagedetails['surveyls_title'];
}
$link = "<li><a href='$rooturl/index.php?sid=".$rows['sid'];
if (isset($_GET['lang']))
{
Expand Down

0 comments on commit 493304e

Please sign in to comment.