7 Jan Edited #1

Can't reset passwords due to fatal PHP error

Ultimate subscriber
I am finding a ton of these errors listed in my errorlog...

[04-Jan-2020 13:14:26 UTC] PHP Fatal error:  Uncaught Error: Call to a member function getByCode() on boolean in /home/xx/public_html/inc/plugins/modpack.php:897
Stack trace:
/home/xx/public_html/inc/class_plugins.php(142): modpack_change_username(Array)
#1 /home/xx/public_html/inc/datahandlers/user.php(1421): pluginSystem->run_hooks(Array, Array)
#2 /home/xx/public_html/member.php(1827): UserDataHandler->update_user()
#3 {main}
  thrown in /home/xx/public_html/inc/plugins/modpack.php on line 897
  • 1
  • 2
Shade 7 Jan
#2
Quite odd. The formatter should be loaded there as well. I need a test FTP account for this.
RocketFoot 7 Jan
#3
PM sent
Shade 8 Jan
#4
You are missing the necessary core edits; you can apply them by reinstalling the plugin.
RocketFoot 8 Jan
#5
OK, I uninstalled and reinstalled the plugin...hopefully that takes care of it!
RocketFoot 2 Apr Edited
#6
I am still getting a ton of errors from this plugin. I also discovered that the plugin is causing my password reset feature to not work properly. I disabled this plugin and password resets work perfect again.

Here is the errors I am getting in my error_log:

[02-Apr-2020 10:11:16 UTC] PHP Fatal error:  Uncaught Error: Call to a member function getByCode() on boolean in /home/xxx/public_html/inc/plugins/modpack.php:897
Stack trace:
/home/xxx/public_html/inc/class_plugins.php(142): modpack_change_username(Array)
#1 /home/xxx/public_html/inc/datahandlers/user.php(1422): pluginSystem->run_hooks(Array, Array)
#2 /home/xxx/public_html/member.php(1826): UserDataHandler->update_user()
#3 {main}
  thrown in /home/xxx/public_html/inc/plugins/modpack.php on line 897
Shade 2 Apr Edited
#7
Reinstall the plugin. Every time you update your board, core edits are lost and you have to reinstall MAP. I've double checked if core edits are still valid and they work just fine on MyBB 1.8.22.

I've added a note in the release thread to make it clear and warn whoever comes across this issue.
RocketFoot 2 Apr Edited
#8
Should I upload all the files or just click uninstall/re-install? I uninstalled and re-installed and the password error returned immediately.
Shade 2 Apr
#9
If the password error is still there, check your inc/datahandler/user.php file: there should be a “modpack” edit. If not, the plugin has failed to apply the edits.
Shade 2 Apr
#10
PS: there’s no need to reupload the plugin. If you’re on 4.0 already, uninstall and install again.