Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

confirmPassword-config currently broken #1463

Closed
Suven opened this issue Mar 30, 2024 · 3 comments
Closed

confirmPassword-config currently broken #1463

Suven opened this issue Mar 30, 2024 · 3 comments

Comments

@Suven
Copy link

Suven commented Mar 30, 2024

Jetstream Version

v5.0.1

Jetstream Stack

Livewire

Laravel Version

v11.1.1

PHP Version

8.3.0

Database Driver & Version

No response

Description

What I want to do

In my settings I want to turn off password-confirmations, as my users do not have passwords.

Desc

Fortify has a feature/config-flag to enable or disable password confirmations for certain actions:

https://github.com/laravel/fortify/blob/1.x/stubs/fortify.php#L154

It seems that this should, at least, toggle wether or not a password is required for activating/modifying 2FA:

https://github.com/laravel/fortify/blob/0c1721f0e50dd63fa3a4b4ad7ade553b821ec015/routes/routes.php#L139

On the PHP-side in Jetstream, that is also supported:

public function enableTwoFactorAuthentication(EnableTwoFactorAuthentication $enable)

But it seems that the feature is hardcoded into the view and thus, setting it to false, has no effect.

https://github.com/laravel/jetstream/blob/5.x/stubs/livewire/resources/views/profile/two-factor-authentication-form.blade.php#L81

Steps To Reproduce

  1. Start a fresh project
  2. Install Jetstream with livewire
  3. Switch the setting Suven/jetstream-example@2b5ac73
  4. It does not take effect
Suven added a commit to Suven/jetstream that referenced this issue Mar 30, 2024
Suven added a commit to Suven/jetstream that referenced this issue Mar 30, 2024
@crynobone crynobone linked a pull request Mar 31, 2024 that will close this issue
Copy link

Thank you for reporting this issue!

As Laravel is an open source project, we rely on the community to help us diagnose and fix issues as it is not possible to research and fix every issue reported to us via GitHub.

If possible, please make a pull request fixing the issue you have described, along with corresponding tests. All pull requests are promptly reviewed by the Laravel team.

Thank you!

@Suven
Copy link
Author

Suven commented Apr 1, 2024

Unfortunately Taylor closed the PR and thus I feel like this issue can also be closed as a consequence. I would still make the argument that, if that feature is not supported on purpose, then the other references to that in fortify and Jetstream should still be removed to prevent confusion

@Suven Suven closed this as completed Apr 1, 2024
@driesvints
Copy link
Member

@Suven I think it's best to just remove the code if you don't want the feature like Taylor suggested. People rely on the boolean checks in jetstream way too much rather than just updating the code since Jetstream is a scaffold.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants