The warning is
Warning: Undefined array key "siteHasPCPs" in /var/www/private_fs/civicrm/templates_c/en_US/%%6F/6F7/6F7BB438%%Contribution.tpl.php on line 378
The only solution I have found is changing line 378.
The line I have is
<?php if ($this->_tpl_vars['siteHasPCPs'] && ! $this->_tpl_vars['payNow']): ?>
If I add
?? NULL after
$this->_tpl_vars['siteHasPCPs'] the line becomes
<?php if ($this->_tpl_vars['siteHasPCPs'] ?? NULL && ! $this->_tpl_vars['payNow']): ?>
Before making changes to the code I tried flushing the caches and deletting the templates so that CiviCRM can regenerate them. For each of these attempts I get no change to the issue.
I am running CiviCRM 5.59.3 with Drupal 9.5.5.
I think this was happening before the upgrade but I cannot be positive. I Googled with some different terms this morning and found an issue related to this on the CiviCRM GitLab instance. https://lab.civicrm.org/dev/core/-/issues/4006#register-pane
If I get an answer there I will update this question.