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

Fix typos in user creation with initial password #1030

Merged
merged 1 commit into from Sep 5, 2019

Conversation

@rwos
Copy link
Contributor

commented Sep 2, 2019

Not sure if I picked the right base branch, let me know :)

This fixes some (I guess) typos in #1017 such that it actually works (on my machine™️).

issue: #764

@amosfolz

This comment has been minimized.

Copy link
Contributor

commented Sep 2, 2019

Good catch. Looks like I missed that line when I updated it in acf4d60.

@rwos

This comment has been minimized.

Copy link
Contributor Author

commented Sep 2, 2019

with the test failure, I'm not so sure anymore if this was actually the correct fix...

@amosfolz

This comment has been minimized.

Copy link
Contributor

commented Sep 2, 2019

I think the test may need to be adjusted, as before it assumed there was never a password field to handle.

@lcharette

This comment has been minimized.

Copy link
Member

commented Sep 2, 2019

$schema->set('value.validators.length.min', $config['site.password.length.min']);
$schema->set('value.validators.length.max', $config['site.password.length.max']);

@@ -167,7 +167,7 @@ public function create(Request $request, Response $response, $args)
$passwordRequest = $this->ci->repoPasswordReset->create($user, $config['password_reset.timeouts.create']);
// If the password_mode is manual, do not send an email to set it. Else, send the email.
if (!isset($data['value'])) {
if ($data['password'] === '') {

This comment has been minimized.

Copy link
@rwos

rwos Sep 3, 2019

Author Contributor

The test failure was actually due to the isset here - it's set to empty string if not set some lines earlier.

@amosfolz

This comment has been minimized.

Copy link
Contributor

commented Sep 5, 2019

Not sure if I picked the right base branch, let me know :)

This fixes some (I guess) typos in #1017 such that it actually works (on my machine™️).

issue: #764

Just a note, it would be helpful to include some details about what's actually broken for others to be able to tell what exactly this is fixing. :-) "Such that it actually works" is not very helpful.

@lcharette lcharette changed the base branch from develop to hotfix Sep 5, 2019

@lcharette lcharette merged commit 4f3f192 into userfrosting:hotfix Sep 5, 2019

2 checks passed

continuous-integration/styleci/pr The analysis has passed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@rwos rwos deleted the rwos:fix-user-pw-creation branch Sep 6, 2019

@rwos

This comment has been minimized.

Copy link
Contributor Author

commented Sep 6, 2019

@amosfolz sure, sorry about that - for the record, the problem was that the frontend validation wouldn't allow entering a password, because it always failed the check against the password confirmation field.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.