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

[stable10] Backport of Check the retypepassword exist in the dom befo… #34834

Merged
merged 1 commit into from
Mar 19, 2019

Conversation

sharidas
Copy link
Contributor

Description

The issue here is, the id retypepassword is not available during the login. Its only available when the lostpassword.js is loaded from https://github.com/owncloud/core/blob/master/core/templates/lostpassword/resetpassword.php#L36. This issue was found in the console log and not in the UI. So in the lostpassword.js before checking if the id retypepassword exist, the objects .val().length was fetched which was throwing error in the web dev console. So in this PR, first we check if the id exist, if so then check the .val().length equal to zero, to remove the warning class and then empty the message text. ( copied from PR #34816)

Related Issue

Motivation and Context

No js errors should be seen in the dev console. Try to check the length of val(), once we verify if the id exist in the DOM.

How Has This Been Tested?

  • Attached screencast here, tested on stable10 branch:
    stable10_lostpasswd

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Database schema changes (next release will require increase of minor version instead of patch)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests only (no source changes)

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:

Open tasks:

  • Backport (if applicable set "backport-request" label and remove when the backport was done)

…re processing

Check the retypepassword exist in the dom before
processing ahead with the val().length. This
patch fixes the error caused for the same.

Signed-off-by: Sujith H <sharidasan@owncloud.com>
@sharidas
Copy link
Contributor Author

Original PR : #34816

Copy link
Contributor

@PVince81 PVince81 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@codecov
Copy link

codecov bot commented Mar 19, 2019

Codecov Report

Merging #34834 into stable10 will increase coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@              Coverage Diff               @@
##             stable10   #34834      +/-   ##
==============================================
+ Coverage       64.22%   64.23%   +<.01%     
  Complexity      19895    19895              
==============================================
  Files            1277     1277              
  Lines           76244    76244              
  Branches         1292     1292              
==============================================
+ Hits            48971    48972       +1     
+ Misses          26894    26893       -1     
  Partials          379      379
Flag Coverage Δ Complexity Δ
#javascript 53.2% <ø> (ø) 0 <ø> (ø) ⬇️
#phpunit 65.39% <ø> (ø) 19895 <ø> (ø) ⬇️
Impacted Files Coverage Δ Complexity Δ
lib/private/Server.php 86.65% <0%> (+0.11%) 253% <0%> (ø) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a0171c2...98e2ab8. Read the comment docs.

@PVince81 PVince81 merged commit de717cd into stable10 Mar 19, 2019
@PVince81 PVince81 deleted the fix-retypepassword-error-stable10 branch March 19, 2019 14:14
@lock lock bot locked as resolved and limited conversation to collaborators Mar 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants