PacktPublishing/Angular-Projects-Second-Edition

[bug: Chapter03 -> issues.service.ts -> updateIssue() ] - The current declaration it's assigning value instead comparing it

Closed this issue · 1 comments

const existingIssue = this.issues.find(i => i.issueNo = issueNo);

Here should be have three (or two) equals operators. The current declaration it's assigning value instead comparing it:

- Current version:
const existingIssue = this.issues.find(i => i.issueNo = issueNo);

- Bugfix version:
const existingIssue = this.issues.find(i => i.issueNo === issueNo);

NOTE: Cheers, i'm enjoying your book!!

Thank you @rodoherrera for spotting that 🙏. I have provided a fix in the exercise branch in case you want to check it out.

I am very happy that you enjoy the book and I hope the rest of the chapters will prove useful to your needs 😊