Skip to content
Permalink
Browse files

Fixed: PHP Notice: Trying to get property of non-object in ...AdminPa…

…geFramework_PageMetaBox_Model.php on line 251
  • Loading branch information...
michaeluno committed Jul 8, 2018
1 parent 37fd313 commit 4e9be0eb05181a73dd4212906b3852b81fedc4fc
Showing with 15 additions and 3 deletions.
  1. +15 −3 development/factory/page_meta_box/AdminPageFramework_PageMetaBox_Model.php
@@ -185,7 +185,10 @@ public function _replyToValidateOptions( $aNewPageOptions, $aOldPageOptions, $oA
$this,
$aSubmitInfo
);
// 3.8.17+ Drop input elements with the `save` argument of false.
$_aNewMetaBoxInputs = $this->oForm->getInputsUnset( $_aNewMetaBoxInputs, $this->oProp->sStructureType );
// If there are validation errors. set the last input.
if ( $this->hasFieldError() ) {
$this->setLastInputs( $_aNewMetaBoxInputsRaw );
@@ -233,15 +236,24 @@ public function _replyToModifyOptionsUpdateStatus( $aStatus ) {
* @since 3.7.0
*/
public function _replyToGetSavedFormData() {
// 3.8.17+ In admin-ajax.php, `$this->oProp->oAdminPage->oProp` is not set for some unknown cases.
// @todo Investigate in which cases it occurs.
$_aPageOptions = isset( $this->oProp->oAdminPage->oProp )
? $this->oProp->oAdminPage->oProp->aOptions
: array();
$_aPageOptions = $this->oUtil->addAndApplyFilter(
$this, // the caller factory object
'options_' . $this->oProp->sClassName,
$this->oProp->oAdminPage->oProp->aOptions
$_aPageOptions
);
return $this->oUtil->castArrayContents(
$this->oForm->getDataStructureFromAddedFieldsets(), // model
$_aPageOptions // data source
);
);
}
/**

0 comments on commit 4e9be0e

Please sign in to comment.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.