Hi Dear friends!
I’m trying to add a section in my journal but I faced with this invalid return for Ajax, What should I do, also this is my php error log:
[22-Nov-2024 19:02:50 Asia/Kabul] PHP Fatal error: Uncaught TypeError: PKP\section\Repository::get(): Argument #1 ($id) must be of type int, null given, called in /home/kjnorg/public_html/plugins/generic/browseBySection/BrowseBySectionPlugin.php on line 159 and defined in /home/kjnorg/public_html/lib/pkp/classes/section/Repository.php:58
Stack trace:
#0 /home/kjnorg/public_html/plugins/generic/browseBySection/BrowseBySectionPlugin.php(159): PKP\section\Repository->get(NULL, 1)
#1 [internal function]: APP\plugins\generic\browseBySection\BrowseBySectionPlugin->initDataSectionFormFields(‘sectionform::in…’, Array)
#2 /home/kjnorg/public_html/lib/pkp/classes/plugins/Hook.php(139): call_user_func_array(Array, Array)
#3 /home/kjnorg/public_html/lib/pkp/classes/plugins/Hook.php(113): PKP\plugins\Hook::run(‘sectionform::in…’, Array)
#4 /home/kjnorg/public_html/lib/pkp/classes/form/Form.php(266): PKP\plugins\Hook::call(‘sectionform::in…’, Array)
#5 /home/kjnorg/public_html/lib/pkp/controllers/grid/settings/sections/form/PKPSectionForm.php(170): PKP\form\Form->initData()
#6 /home/kjnorg/public_html/controllers/grid/settings/sections/form/SectionForm.php(81): PKP\controllers\grid\settings\sections\form\PKPSectionForm->initData()
#7 /home/kjnorg/public_html/controllers/grid/settings/sections/SectionGridHandler.php(214): APP\controllers\grid\settings\sections\form\SectionForm->initData()
#8 /home/kjnorg/public_html/controllers/grid/settings/sections/SectionGridHandler.php(196): APP\controllers\grid\settings\sections\SectionGridHandler->editSection(Array, Object(APP\core\Request))
#9 [internal function]: APP\controllers\grid\settings\sections\SectionGridHandler->addSection(Array, Object(APP\core\Request))
#10 /home/kjnorg/public_html/lib/pkp/classes/core/PKPRouter.php(334): call_user_func(Array, Array, Object(APP\core\Request))
#11 /home/kjnorg/public_html/lib/pkp/classes/core/PKPComponentRouter.php(291): PKP\core\PKPRouter->_authorizeInitializeAndCallRequest(Array, Object(APP\core\Request), Array)
#12 /home/kjnorg/public_html/lib/pkp/classes/core/Dispatcher.php(165): PKP\core\PKPComponentRouter->route(Object(APP\core\Request))
#13 /home/kjnorg/public_html/lib/pkp/classes/core/PKPApplication.php(395): PKP\core\Dispatcher->dispatch(Object(APP\core\Request))
#14 /home/kjnorg/public_html/index.php(21): PKP\core\PKPApplication->execute()
#15 {main}
thrown in /home/kjnorg/public_html/lib/pkp/classes/section/Repository.php on line 58
Thanks for your help.