I applied the latest martex to the website. Updated bootstrap to 5.5.20.
Tried to use the contact us form and website crashed. Appears to be associated with the warning I mentioned in the last post. Error message included below.


The website encountered an unexpected error. Try again later.

TypeError: Drupal\Component\Utility\Html::escape(): Argument #1 ($text) must be of type string, null given, called in /home/pmkuntvbe/public_html/core/lib/Drupal/Component/Render/FormattableMarkup.php on line 238 in Drupal\Component\Utility\Html::escape() (line 433 of core/lib/Drupal/Component/Utility/Html.php).

Drupal\Component\Render\FormattableMarkup::placeholderEscape(NULL) (Line: 187)
Drupal\Component\Render\FormattableMarkup::placeholderFormat('[@form] @subject', Array) (Line: 195)
Drupal\Core\StringTranslation\TranslatableMarkup->render() (Line: 15)
Drupal\Core\StringTranslation\TranslatableMarkup->__toString() (Line: 138)
Drupal\contact\Hook\ContactHooks->mail('page_mail', Array, Array) (Line: 369)
Drupal\Core\Extension\ModuleHandler->invoke('contact', 'mail', Array) (Line: 274)
Drupal\Core\Mail\MailManager->doMail('contact', 'page_mail', 'admin@example.com', 'en', Array, 'mgregory@uanmi.com', 1) (Line: 181)
Drupal\Core\Mail\MailManager->{closure:Drupal\Core\Mail\MailManager::mail():180}() (Line: 627)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 180)
Drupal\Core\Mail\MailManager->mail('contact', 'page_mail', 'admin@example.com', 'en', Array, 'mgregory@uanmi.com') (Line: 114)
Drupal\contact\MailHandler->sendMailMessages(Object, Object) (Line: 219)
Drupal\contact\MessageForm->save(Array, Object)
call_user_func_array(Array, Array) (Line: 105)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 43)
Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 589)
Drupal\Core\Form\FormBuilder->processForm('contact_message_feedback_form', Array, Object) (Line: 321)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 48)
Drupal\Core\Entity\EntityFormBuilder->getForm(Object, 'default') (Line: 241)
Drupal\contact_block\Plugin\Block\ContactBlock->build() (Line: 186)
Drupal\block\BlockViewBuilder::preRender(Array)
call_user_func_array('Drupal\block\BlockViewBuilder::preRender', Array) (Line: 107)
Drupal\Core\Render\Renderer->doTrustedCallback('Drupal\block\BlockViewBuilder::preRender', Array, 'Render #pre_render callbacks must be methods of a class that implements \Drupal\Core\Security\TrustedCallbackInterface or be an anonymous function. The callback was %s. See https://www.drupal.org/node/2966725', 'exception', 'Drupal\Core\Render\Element\RenderCallbackInterface') (Line: 876)
Drupal\Core\Render\Renderer->doCallback('#pre_render', 'Drupal\block\BlockViewBuilder::preRender', Array) (Line: 438)
Drupal\Core\Render\Renderer->doRender(Array, Object) (Line: 250)
Drupal\Core\Render\Renderer->doRenderRoot(Array, Object) (Line: 141)
Drupal\Core\Render\Renderer->{closure:Drupal\Core\Render\Renderer::renderInIsolation():140}() (Line: 627)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 140)
Drupal\Core\Render\Renderer->renderInIsolation(Array) (Line: 167)
Drupal\Core\Render\Renderer->doRenderPlaceholder(Array) (Line: 729)
Drupal\Core\Render\Renderer->{closure:Drupal\Core\Render\Renderer::replacePlaceholders():728}()
Fiber->start() (Line: 737)
Drupal\Core\Render\Renderer->replacePlaceholders(Array) (Line: 262)
Drupal\Core\Render\Renderer->doRenderRoot(Array, Object) (Line: 141)
Drupal\Core\Render\Renderer->{closure:Drupal\Core\Render\Renderer::renderInIsolation():140}() (Line: 627)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 140)
Drupal\Core\Render\Renderer->renderInIsolation(Array) (Line: 111)
Drupal\Core\Render\Renderer->renderRoot(Array) (Line: 253)
Drupal\Core\Render\HtmlResponseAttachmentsProcessor->renderPlaceholders(Object) (Line: 74)
Drupal\big_pipe\Render\BigPipeResponseAttachmentsProcessor->processAttachments(Object) (Line: 45)
Drupal\Core\EventSubscriber\HtmlResponseSubscriber->onRespond(Object, 'kernel.response', Object) (Line: 246)
Symfony\Component\EventDispatcher\EventDispatcher::{closure:Symfony\Component\EventDispatcher\EventDispatcher::optimizeListeners():241}(Object, 'kernel.response', Object) (Line: 206)
Symfony\Component\EventDispatcher\EventDispatcher->callListeners(Array, 'kernel.response', Object) (Line: 56)
Symfony\Component\EventDispatcher\EventDispatcher->dispatch(Object, 'kernel.response') (Line: 216)
Symfony\Component\HttpKernel\HttpKernel->filterResponse(Object, Object, 1) (Line: 204)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 53)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 116)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 90)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 53)
Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 715)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

Comments

The errror message is

The errror message is relating to contact module, not with our theme.

We can confirm that we updated our theme to Bootstrap 5.5.20 on our local site and had no problems.

I have no idea why the

I have no idea why the contact module would cause an error. The error went straight to the undefined array in the theme where it failed.

I have a backup of the site, but as it is under development there is very little content, so it will be faster to start from scratch.

Supported via email

Supported via email