Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Update check fault
If I open the update check in the menu there is an error shown:
Fatal error: Call to a member function on a non-object in /var/www/s16u38/html/hessen/lussumo/themes/settings_update_check_nopostback.php on line 29
is it "normal" for svn at the moment?
Fatal error: Call to a member function on a non-object in /var/www/s16u38/html/hessen/lussumo/themes/settings_update_check_nopostback.php on line 29
is it "normal" for svn at the moment?
0
This discussion has been closed.
Comments
What revision are you on?
If I check the update, everything seems to be alright:
...but it only seems. This notification doesn't disappear:
Should this update status be written to the database? I think my database structure is inconsistent... I have following rows there:
* Browse LUM_Category
* Browse LUM_CategoryBlock
* Browse LUM_CategoryRoleBlock
* Browse LUM_Clipping
* Browse LUM_Comment
* Browse LUM_CommentBlock
* Browse LUM_Discussion
* Browse LUM_DiscussionUserWhisperFrom
* Browse LUM_DiscussionUserWhisperTo
* Browse LUM_IpHistory
* Browse LUM_Role
* Browse LUM_Style
* Browse LUM_User
* Browse LUM_UserBlock
* Browse LUM_UserBookmark
* Browse LUM_UserDiscussionWatch
* Browse LUM_UserRoleHistory
* Browse LUM_UserSearch
$Configuration['LAST_UPDATE'] = '1147040566';
my guess is that your library/Framework/Framework.Control.UpdateCheck.php is out of date, but i'll defer to mark.
If I were you, I'd back up my conf files and then delete the entire repository and re-check-out the whole thing from svn. Then paste in your old conf files.
I have reinstalled Vanilla, now the notification-style is visible, but the error is still there.
Open up library/Framework/Framework.Control.UpdateCheck.php
From lines 27 to 40, change it from this:
if ($this->IsPostBack) { $this->Context->PageTitle = $this->Context->GetDefinition('UpdatesAndReminders'); $this->ReminderSelect = $this->Context->ObjectFactory->NewObject($this->Context, 'Select'); $this->ReminderSelect->Name = 'ReminderRange'; $this->ReminderSelect->AddOption('', $this->Context->GetDefinition('Never')); $this->ReminderSelect->AddOption('Weekly', $this->Context->GetDefinition('Weekly')); $this->ReminderSelect->AddOption('Monthly', $this->Context->GetDefinition('Monthly')); $this->ReminderSelect->AddOption('Quarterly', $this->Context->GetDefinition('Quarterly')); $this->ReminderSelect->SelectedValue = $this->Context->Configuration['UPDATE_REMINDER']; $SettingsFile = $this->Context->Configuration['APPLICATION_PATH'].'conf/settings.php'; }
to this
echo 'IsPostBack: '.GetBool($this->IsPostBack); if ($this->IsPostBack) { echo '<div>about to set up ReminderSelect</div>'; $this->Context->PageTitle = $this->Context->GetDefinition('UpdatesAndReminders'); $this->ReminderSelect = $this->Context->ObjectFactory->NewObject($this->Context, 'Select'); $this->ReminderSelect->Name = 'ReminderRange'; $this->ReminderSelect->AddOption('', $this->Context->GetDefinition('Never')); $this->ReminderSelect->AddOption('Weekly', $this->Context->GetDefinition('Weekly')); $this->ReminderSelect->AddOption('Monthly', $this->Context->GetDefinition('Monthly')); $this->ReminderSelect->AddOption('Quarterly', $this->Context->GetDefinition('Quarterly')); $this->ReminderSelect->SelectedValue = $this->Context->Configuration['UPDATE_REMINDER']; print_r($this->ReminderSelect); $SettingsFile = $this->Context->Configuration['APPLICATION_PATH'].'conf/settings.php'; }
See, on line 29 of settings_update_check_nopostback.php, it calls the get method of the ReminderSelect object. And according to your error, that object isn't properly defined. So I want to find out why the hell it's happening.
Once you've changed that code, save the file and go back to the updatecheck form. There will be a bunch of garbage spit out onto the screen (I hope). Copy and paste (or screen grab) it in here.
<?php /* * Copyright 2003 - 2005 Mark O'Sullivan * This file is part of Vanilla. * Vanilla is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. * Vanilla is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. * You should have received a copy of the GNU General Public License along with Vanilla; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * The latest source code for Vanilla is available at www.lussumo.com * Contact Mark O'Sullivan at mark [at] lussumo [dot] com * * Description: The UpdateCheck control is used to ping the lussumo.com server to check for upgrades to Vanilla. */ class UpdateCheck extends PostBackControl { var $LussumoMessage; function UpdateCheck(&$Context) { $this->Name = 'UpdateCheck'; $this->ValidActions = array('UpdateCheck', 'ProcessUpdateCheck'); $this->Constructor($Context); if (!$this->Context->Session->User->Permission('PERMISSION_CHECK_FOR_UPDATES')) { $this->IsPostBack = 0; } elseif ($this->IsPostBack && $this->PostBackAction == 'ProcessUpdateCheck') { // Ping lussumo.com for update information $Lines = file($this->Context->Configuration['UPDATE_URL'] .'?Application='.APPLICATION .'&Version='.APPLICATION_VERSION .'&Language='.$this->Context->Configuration['LANGUAGE']); $this->LussumoMessage = implode('\r\n', $Lines); $this->PostBackValidated = 1; } $this->CallDelegate('Constructor'); } function Render_ValidPostBack() { $this->CallDelegate('PreValidPostBackRender'); include(ThemeFilePath($this->Context->Configuration, 'settings_update_check_validpostback.php')); $this->CallDelegate('PostValidPostBackRender'); } function Render_NoPostBack() { if ($this->IsPostBack) { $this->CallDelegate('PreNoPostBackRender'); $this->PostBackParams->Clear(); $this->PostBackParams->Set('PostBackAction', 'ProcessUpdateCheck'); include(ThemeFilePath($this->Context->Configuration, 'settings_update_check_nopostback.php')); $this->CallDelegate('PostNoPostBackRender'); } } } ?>
I think my RapidSVN doesn't check the People and Framework folders properly....
Framework: revision 38
People: revision 33
Your framework and people repositories aren't getting updated.
Do you know how to turn the automatic update of externals on?
Thank you guys