Hello,
i have a similar problem with Edit My Profile and PHP 8. In this case it is seems to be Code in the template.
Thanks for advice and with best regards
Maurizio
`Notice: Undefined property: Joomla\Component\Users\Site\View\Profile\HtmlView::$twofactormethods in ../templates/gk_storefront/html/com_users/profile/edit.php on line 83
Warning: count(): Parameter must be an array or an object that implements Countable in ../templates/gk_storefront/html/com_users/profile/edit.php on line 83`
After commenting out bginning in line 83 all works well.
`<!--<?php // if (count($this->twofactormethods) > 1): ?>
<fieldset>
<legend><?php echo JText::_('COM_USERS_PROFILE_TWO_FACTOR_AUTH') ?></legend>
<div class="control-group">
<div class="control-label">
<label id="jform_twofactor_method-lbl" for="jform_twofactor_method" class="hasTooltip"
title="<strong><?php echo JText::_('COM_USERS_PROFILE_TWOFACTOR_LABEL') ?></strong><br/><?php echo JText::_('COM_USERS_PROFILE_TWOFACTOR_DESC') ?>">
<?php echo JText::_('COM_USERS_PROFILE_TWOFACTOR_LABEL'); ?>
</label>
</div>
<div class="controls">
<?php echo JHtml::_('select.genericlist', $this->twofactormethods, 'jform[twofactor][method]', array('onchange' => 'Joomla.twoFactorMethodChange()'), 'value', 'text', $this->otpConfig->method, 'jform_twofactor_method', false) ?>
</div>
</div>
<div id="com_users_twofactor_forms_container">
<?php foreach($this->twofactorform as $form): ?>
<?php $style = $form['method'] == $this->otpConfig->method ? 'display: block' : 'display: none'; ?>
<div id="com_users_twofactor_<?php echo $form['method'] ?>" style="<?php echo $style; ?>">
<?php echo $form['form'] ?>
</div>
<?php endforeach; ?>
</div>
</fieldset>
<fieldset>
<legend>
<?php echo JText::_('COM_USERS_PROFILE_OTEPS') ?>
</legend>
<div class="alert alert-info">
<?php echo JText::_('COM_USERS_PROFILE_OTEPS_DESC') ?>
</div>
<?php if (empty($this->otpConfig->otep)): ?>
<div class="alert alert-warning">
<?php echo JText::_('COM_USERS_PROFILE_OTEPS_WAIT_DESC') ?>
</div>
<?php else: ?>
<?php foreach ($this->otpConfig->otep as $otep): ?>
<span class="span3">
<?php echo substr($otep, 0, 4) ?>-<?php echo substr($otep, 4, 4) ?>-<?php echo substr($otep, 8, 4) ?>-<?php echo substr($otep, 12, 4) ?>
</span>
<?php endforeach; ?>
<div class="clearfix"></div>
<?php endif; ?>
</fieldset>
<?php //endif; ?>
-->`