Last active
December 13, 2015 22:19
-
-
Save Ikke/4983768 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function upgrade_3_5_2b2() { //line 625 | |
// fixing the effects of a previous bug affecting non-MyISAM users | |
if ( is_null( yarpp_get_option('weight') ) || //<-- this is one point where it errors out | |
!is_array( yarpp_get_option('weight') ) ) { | |
$weight = $this->default_options['weight']; | |
// if we're still not using MyISAM | |
if ( !yarpp_get_option('myisam_override') && | |
$this->myisam_check() !== true ) { | |
unset( $weight['title'] ); | |
unset( $weight['body'] ); | |
} | |
yarpp_set_option(array('weight' => $weight)); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/class-core.php b/class-core_new.php | |
index d71ea77..39d6e32 100755 | |
--- a/class-core.php | |
+++ b/class-core.php | |
@@ -624,16 +624,16 @@ class YARPP { | |
function upgrade_3_5_2b2() { | |
// fixing the effects of a previous bug affecting non-MyISAM users | |
- if ( is_null( yarpp_get_option('weight') ) || | |
- !is_array( yarpp_get_option('weight') ) ) { | |
+ if ( is_null( $this->get_option('weight') ) || | |
+ !is_array( $this->get_option('weight') ) ) { | |
$weight = $this->default_options['weight']; | |
// if we're still not using MyISAM | |
- if ( !yarpp_get_option('myisam_override') && | |
+ if ( !$this->get_option('myisam_override') && | |
$this->diagnostic_myisam_posts() !== true ) { | |
unset( $weight['title'] ); | |
unset( $weight['body'] ); | |
} | |
- yarpp_set_option(array('weight' => $weight)); | |
+ $this->set_option(array('weight' => $weight)); | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment