View Issue Details

IDProjectCategoryView StatusLast Update
13923Bug reports[All Projects] ComfortUpdatepublic2018-08-07 17:01
ReporterArneD Assigned Tomarkusfluer  
PrioritynoneSeverityblock 
Status closedResolutionfixed 
Product Version3.13.x 
Target VersionFixed in Version3.13.x 
Summary13923: unable to log in into Admin Backend. Error "Undefined variable: security_update_available"
Description

When login Into the Backend an error occurred.

Additional Information

PHP notice

Undefined variable: security_update_available

/survey/application/models/UpdateForm.php(600)

588 foreach ($updates as $update) {
589 if ($update->security_update) {
590 $security_update_available = true;
591 }
592
593 if ($update->branch != 'master') {
594 $unstable_update_available = true;
595 }
596 }
597 }
598 }
599 Yii::app()->session['update_result'] = $update_available;
600 Yii::app()->session['security_update'] = $security_update_available;
601
602 // If only one update is available and it's an unstable one, then it will be displayed in a different color, and will be removed, not minified when clicked
603 if (count((array) $updates) == 1 && $unstable_update_available) {
604 Yii::app()->session['unstable_update'] = $unstable_update_available;
605 } else {
606 Yii::app()->session['unstable_update'] = false;
607 }
608
609 $next_update_check = $today->add(new DateInterval('P1D'));
610 Yii::app()->session['next_update_check'] = $next_update_check;
611 $updates = array('result'=>$update_available, 'security_update'=>$security_update_available, 'unstable_update'=>$unstable_update_available);
612 } else {
Stack Trace
#0

  • /survey/framework/base/CComponent.php(111): UpdateForm->getUpdateNotification()
    #1
    – /survey/application/core/Survey_Common_Action.php(457): CComponent->__get("updateNotification")
    452 }
    453
    454 $aData['sitename'] = Yii::app()->getConfig("sitename");
    455
    456 $updateModel = new UpdateForm();
    457 $updateNotification = $updateModel->updateNotification;
    458 $aData['showupdate'] = Yii::app()->getConfig('updatable') && $updateNotification->result && !$updateNotification->unstable_update;
    459
    460 // Fetch extra menus from plugins, e.g. last visited surveys
    461 $aData['extraMenus'] = $this->fetchExtraMenus($aData);
    462
    #2
    – /survey/application/views/admin/super/layout_main.php(8): Survey_Common_Action->_showadminmenu(array("issuperadmin" => true, "showLastSurvey" => true, "surveyTitle" => "survey", "surveyUrl" => "/survey/index.php/admin/survey/sa/view/surveyid/", ...))
    03 //All paths relative from /application/views
    04
    05 //headers will be generated with the template file /admin/super/header.php
    06 $this->_showHeaders($aData);
    07 //The adminmenu bar will be generated from /admin/super/adminmenu.php
    08 $this->_showadminmenu($aData);
    09 // Generated through /admin/usergroup/usergroupbar_view
    10 $this->_userGroupBar($aData);
    11 echo "<!-- BEGIN LAYOUT_MAIN -->";
    12 // Generated through /admin/super/fullpagebar_view
    13 $this->_fullpagebar($aData);
    #3
    – /survey/application/core/Survey_Common_Action.php(239): require("/survey/application/views/a...")
    234 }
    235
    236 if ($return) {
    237 ob_start();
    238 ob_implicit_flush(0);
    239 require($viewFile);
    240 return ob_get_clean();
    241 } else {
    242 require($viewFile);
    243 }
    244 }
    #4
  • /survey/application/core/Survey_Common_Action.php(339): Survey_Common_Action->renderInternal("/survey/application/views/a...", array("content" => "<x-test id="action::index"></x-test> <!-- Welcome view --> <div...", "aData" => array("issuperadmin" => true, "showLastSurvey" => true, "surveyTitle" => "Titel (ID:nn)", "surveyUrl" => "/survey/index.php/admin/survey/sa/view/surveyid/nn", ...)), true)
    #5
  • /survey/application/controllers/admin/index.php(85): Survey_Common_Action->_renderWrappedTemplate("super", "welcome", array("issuperadmin" => true, "showLastSurvey" => true, "surveyTitle" => "Titel (ID:nn)", "surveyUrl" => "/survey/index.php/admin/survey/sa/view/surveyid/nn", ...))
    #6
    unknown(0): Index->run()
    #7
  • /survey/framework/web/actions/CAction.php(109): ReflectionMethod->invokeArgs(Index, array())
    #8
  • /survey/application/core/Survey_Common_Action.php(83): CAction->runWithParamsInternal(Index, ReflectionMethod, array())
    #9
  • /survey/framework/web/CController.php(308): Survey_Common_Action->runWithParams(array())
    #10
  • /survey/framework/web/CController.php(286): CController->runAction(Index)
    #11
  • /survey/framework/web/CController.php(265): CController->runActionWithFilters(Index, array())
    #12
  • /survey/application/controllers/AdminController.php(158): CController->run("")
    #13
  • /survey/framework/web/CWebApplication.php(282): AdminController->run("")
    #14
  • /kunden/xx/webseiten/survey/survey/framework/web/CWebApplication.php(141): CWebApplication->runController("admin")
    #15
  • /kunden/xx/webseiten/survey/survey/framework/base/CApplication.php(185): CWebApplication->processRequest()
    #16
  • /kunden/xx/webseiten/survey/survey/index.php(194): CApplication->run()
    2018-07-31 10:47:05 Apache/2.4.29 Yii Framework/1.1.19
TagsNo tags attached.
Complete LimeSurvey version number (& build)latest Version
I will donate to the project if issue is resolvedNo
BrowserSafari
Database & DB-Versionmysql 5.19
Server OS (if known)Linux
Webserver software & version (if known)nginx
PHP Version5.56

Activities

ArneD

ArneD

2018-07-31 15:00

reporter   ~48634

we fixed it in our system:

updateform.php, line 586 ==>

$security_update_available = false;
$unstable_update_available = false;

move 3 lines up, before "if"

LouisGac

LouisGac

2018-08-01 10:40

manager   ~48637

Markus, your commit:
https://github.com/LimeSurvey/LimeSurvey/commit/f13c111cd8096ecc0c29a54cc7e24bf0a7b093a8#diff-a5a0b0d60aa23fc35fbdae69a2d8b48d

markusfluer

markusfluer

2018-08-01 11:32

administrator   ~48638

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=27735

markusfluer

markusfluer

2018-08-07 17:01

administrator   ~48695

Release 3.14.2+180807

Related Changesets

LimeSurvey: master 87654a26

2018-08-01 11:31:48

markusfluer

Details Diff
Fixed issue 13923: unable to log in into Admin Backend. Error "Undefined variable: security_update_available" Affected Issues
13923
mod - application/models/UpdateForm.php Diff File

Issue History

Date Modified Username Field Change
2018-07-31 12:48 ArneD New Issue
2018-07-31 12:48 ArneD Status new => assigned
2018-07-31 12:48 ArneD Assigned To => LouisGac
2018-07-31 15:00 ArneD Note Added: 48634
2018-08-01 10:40 LouisGac Assigned To LouisGac => markusfluer
2018-08-01 10:40 LouisGac Note Added: 48637
2018-08-01 11:32 markusfluer Changeset attached => LimeSurvey master 87654a26
2018-08-01 11:32 markusfluer Note Added: 48638
2018-08-01 11:32 markusfluer Resolution open => fixed
2018-08-01 11:32 markusfluer Status assigned => resolved
2018-08-01 11:32 markusfluer Fixed in Version => 3.13.x
2018-08-07 17:01 markusfluer Status resolved => closed
2018-08-07 17:01 markusfluer Note Added: 48695