On resetting I get Password must not contain the username

Created on 21 October 2025, 3 days ago

When changing password I get Password must not contain the username event tho it does not.

The issue is on line 29: stripos($password, $user->getAccountName()). If $password is null or empty, stripos() in PHP 8+ will trigger a deprecation warning.

This patch fixes two issues:

  • Skips password validation when the password field is empty on change_pwd_form
  • Only sets username if the 'name' field exists in the form (prevents NULL username error)
🐛 Bug report
Status

Needs review

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom c_archer Cumbria

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024