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

Ignore whatsapp-web.js type definition - Fix #600 #602

Merged
merged 1 commit into from
Feb 22, 2024

Conversation

allgood
Copy link
Contributor

@allgood allgood commented Oct 26, 2023

Looks like whatsapp-web.js on version 1.23.0 changed the type definition of Location, mostly because a change on how to send the location. They removed the values for name, address, url and description from the Location object and created an Option object that includes only name, address and url.

BUT, received location stills come with the old format AND the code fails to build because of the type differences.

This pull request make whaticket compatible with whatsapp-web.js 1.23.0 bypassing typescript checks for two lines that uses the location.description value of messages.

I will open an issue on whatsapp-web.js so we can remove this bypass on the future.

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link

@aalonzolu aalonzolu left a comment

Choose a reason for hiding this comment

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

Having the same issue, thanks.

@allgood
Copy link
Contributor Author

allgood commented Nov 3, 2023

There is a PR on whatsapp-web.js that will change the definition of the Location received too, so next update will have to be adapted.

@w3nder w3nder merged commit 1c64303 into canove:master Feb 22, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants