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

Password component throws an error when handling keyup events and feedback is false #6334

Closed
fperezgaliana opened this issue Aug 16, 2018 · 3 comments
Assignees
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@fperezgaliana
Copy link

I'm submitting a ... (check one with "x")

[ X ] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35

Plunkr Case (Bug Reports)

https://stackblitz.com/edit/angular-datnyq?embed=1&file=src/app/app.component.html

Current behavior
When you set feedback to false on a pPassword component and try to handle keyup events, the application throws the following error:

imagen

It seems that the component tries to access to some properties of the password strength helper, but it can't because it doesn't exist.

Expected behavior
It should manage internally whether the feedback component exists or not, to avoid accessing it in case that feedback is false.

Minimal reproduction of the problem with instructions
To reproduce the problem, just drop a pPassword component with [feedback] = false and bind a keyup event handler. For example:

<input name="password" type="password" pPassword [feedback]="false" (keyup)="checkForm($event)" [(ngModel)]="pass"/>

What is the motivation / use case for changing the behavior?

Please tell us about your environment:

Kubuntu 18.04 64 bits, NPM 6.4.0

  • Angular version: 5.X

Angular: 6.1.3

  • PrimeNG version: 5.X

PrimeNG 6.1.2

  • Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]

I tested it on Chrome and Firefox and it's the same on both.

  • Language: [all | TypeScript X.X | ES6/7 | ES5]
    TypeScript

  • Node (for AoT issues): node --version =
    Node v10.6.0

@skormel
Copy link

skormel commented Aug 22, 2018

I have the same problem after updating to version 6.1.2.

@antoniogeroncio
Copy link

I have the same problem after updating 6.1.2

@skormel skormel mentioned this issue Aug 24, 2018
@skormel
Copy link

skormel commented Aug 24, 2018

PR send #6389

@cagataycivici cagataycivici self-assigned this Aug 29, 2018
@cagataycivici cagataycivici added the Type: Bug Issue contains a bug related to a specific component. Something about the component is not working label Aug 29, 2018
@cagataycivici cagataycivici added this to the 6.1.3 milestone Aug 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Projects
None yet
Development

No branches or pull requests

4 participants