User tests: Successful: Unsuccessful:
Sometimes is a user needed when running console commands. As cli per se doesn't know a user, this pr adds a new user argument, when set, does the console application load a user object before executing the command. The argument has the name --user
and accepts either the user id or username.
php cli/joomla.php user:reset-password --username test --password newpw
--user
argument (replace manager with a username from your system):php cli/joomla.php user:reset-password --user manager --username test --password newpw
The username got changed but no action log entry was made and log in on the front is possible.
The username got changed and an action log entry was made for the user manager that he changed the user test and log in on the front is possible.
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
Status | New | ⇒ | Pending |
Category | ⇒ | Libraries |
Not on cli
Yes, as long as we are still discussing things I will not make more changes
Labels |
Added:
PR-5.3-dev
|
This is correct. But I changed the code and to have a more real world test scenario.
Category | Libraries | ⇒ | CLI Libraries |
Labels |
Added:
Feature
|
Looks good to me
Labels |
Added:
Maintainers Checked
|
Added an extra check, so the user will only be loaded when it is not a guest in the console application.
Surely there must be some sort of authentication required