• Resolved mtg169

    (@mtg169)


    The 4.1.0 update is throwing the following fatal error on multiple sites. Can you add better data type handling?

    PHP Fatal error:  Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/DatasetModel.php:232
    Stack trace:
    #0 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/ProjectModel.php(623): MPG_DatasetModel::create_index(3)
    #1 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/helpers/Helper.php(505): MPG_ProjectModel::mpg_update_project_by_id(3, Array, true)
    #2 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(63): MPG_Helper::mpg_live_project_data_update(Object(stdClass))
    #3 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #4 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #5 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #6 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #7 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #8 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #9 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #10 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #11 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #12 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #13 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #14 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #15 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #16 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #17 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #18 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #19 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #20 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #21 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #22 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #23 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #24 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #25 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #26 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #27 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/LogsController.php(33): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #28 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/CoreModel.php(73): MPG_LogsController::mpg_write('', 'warning', 'Project has no ...')
    #29 /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/controllers/CoreController.php(223): MPG_CoreModel::mpg_get_redirect_rules('/actuator/env/')
    #30 /wordpress/core/6.8.2/wp-includes/class-wp-hook.php(324): MPG_CoreController::mpg_view_multipages_standard('')
    #31 /wordpress/core/6.8.2/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)
    #32 /wordpress/core/6.8.2/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
    #33 /wordpress/core/6.8.2/wp-includes/template-loader.php(13): do_action('template_redire...')
    #34 /wordpress/core/6.8.2/wp-blog-header.php(19): require_once('/wordpress/core...')
    #35 /wordpress/core/6.8.2/index.php(17): require('/wordpress/core...')
    #36 {main}
    thrown in /srv/htdocs/wp-content/plugins/multiple-pages-generator-by-porthas/models/DatasetModel.php on line 232
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Vytis

    (@bvytis)

    Hi @mtg169,

    Thank you for reporting this issue and apologies for the inconvenience.
    We added a fix and it will be released soon with the next release of the plugin this week.

    Plugin Support Vytis

    (@bvytis)

    Hi @mtg169,

    Today we made a release where this issue is addressed. Thanks again for reporting it.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Uncaught TypeError: count()’ is closed to new replies.