Skip to content

Commit

Permalink
Dev: Remove unused variables in _niceExit() and fix surveyid to doFoo…
Browse files Browse the repository at this point in the history
…ter()
  • Loading branch information
olleharstedt committed Jan 20, 2017
1 parent 631dc5a commit 459821d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions application/controllers/survey/index.php
Expand Up @@ -701,12 +701,11 @@ function _niceExit(&$redata, $iDebugLine, $sTemplateDir = null, $asMessage = arr

if(isset($redata['surveyid']) && $redata['surveyid'] && !isset($thisurvey))
{
$thissurvey=getSurveyInfo($redata['surveyid']);
$sTemplateDir= $oTemplate->viewPath;
$surveyId = $redata['surveyid'];
}
else
{
$sTemplateDir= $oTemplate->viewPath;
$surveyId = null;
}
sendCacheHeaders();

Expand All @@ -719,7 +718,7 @@ function _niceExit(&$redata, $iDebugLine, $sTemplateDir = null, $asMessage = arr
$this->_printMessage($asMessage);
$this->_printTemplateContent($oTemplate->viewPath.'/endpage.pstpl', $redata, $iDebugLine);

doFooter($thissurvey['sid']);
doFooter($surveyId); // It's OK for surveyId to be null here
exit;
}

Expand Down

0 comments on commit 459821d

Please sign in to comment.