Всем доброго времени суток!
Пришлось переходить с php 7.4 на php 8.1, т.к. подключенные решения требуют php 8.1, связаться с разработчиком кастомных элементов нет возможности, человек уехал из страны и не выходит на связь...
Почитав форумы понимаю что необходимо написать проверку на массив изменив 894 строку кода, но как это сделать не знаю...
Цитата |
---|
[TypeError] current(): Argument #1 ($array) must be of type array, null given (0) /home/nkaby/public_html/bitrix/templates/aspro_next/components/bitrix/catalog.element/main2_custom/template.php:894 #0: current /home/nkaby/public_html/bitrix/templates/aspro_next/components/bitrix/catalog.element/main2_custom/template.php:894 #1: include(string) /home/nkaby/public_html/bitrix/modules/main/classes/general/component_template.php:790 #2: CBitrixComponentTemplate->__IncludePHPTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component_template.php:885 #3: CBitrixComponentTemplate->IncludeTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:776 #4: CBitrixComponent->showComponentTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:716 #5: CBitrixComponent->includeComponentTemplate /home/nkaby/public_html/bitrix/modules/iblock/lib/component/base.php:4707 #6: Bitrix\Iblock\Component\Base->loadData /home/nkaby/public_html/bitrix/modules/iblock/lib/component/base.php:4686 #7: Bitrix\Iblock\Component\Base->initialLoadAction /home/nkaby/public_html/bitrix/modules/iblock/lib/component/element.php:284 #8: Bitrix\Iblock\Component\Element->initialLoadAction #9: call_user_func /home/nkaby/public_html/bitrix/modules/iblock/lib/component/base.php:4873 #10: Bitrix\Iblock\Component\Base->doAction /home/nkaby/public_html/bitrix/modules/iblock/lib/component/base.php:4891 #11: Bitrix\Iblock\Component\Base->executeComponent /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:660 #12: CBitrixComponent->includeComponent /home/nkaby/public_html/bitrix/modules/main/classes/general/main.php:1072 #13: CAllMain->IncludeComponent /home/nkaby/public_html/bitrix/templates/aspro_next/components/bitrix/catalog/main/page_blocks/element_custom.php:2 #14: include_once(string) /home/nkaby/public_html/bitrix/templates/aspro_next/components/bitrix/catalog/main/element_normal.php:80 #15: include_once(string) /home/nkaby/public_html/bitrix/templates/aspro_next/components/bitrix/catalog/main/element.php:149 #16: include(string) /home/nkaby/public_html/bitrix/modules/main/classes/general/component_template.php:790 #17: CBitrixComponentTemplate->__IncludePHPTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component_template.php:885 #18: CBitrixComponentTemplate->IncludeTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:776 #19: CBitrixComponent->showComponentTemplate /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:716 #20: CBitrixComponent->includeComponentTemplate /home/nkaby/public_html/bitrix/components/bitrix/catalog/component.php:323 #21: include(string) /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:607 #22: CBitrixComponent->__includeComponent /home/nkaby/public_html/bitrix/modules/main/classes/general/component.php:684 #23: CBitrixComponent->includeComponent /home/nkaby/public_html/bitrix/modules/main/classes/general/main.php:1072 #24: CAllMain->IncludeComponent /home/nkaby/public_html/catalog/index.php:584 #25: include_once(string) /home/nkaby/public_html/bitrix/modules/main/include/urlrewrite.php:184 #26: include_once(string) /home/nkaby/public_html/bitrix/urlrewrite.php:2 ---------- |
/home/nkaby/public_html/bitrix/templates/aspro_next/componen
ts/bitrix/catalog.element/main2_custom/template.php:894
Код |
---|
<?$arCurPriceType = current($arResult['PRICE_MATRIX']['COLS']); |
заранее благодарю, если кто-то поможет!