TwiN / whois

Lightweight WHOIS client in Go
MIT License
7 stars 6 forks source link

Fix: Wrong expiry date check + domain without info #9

Closed allanviana-logcomex closed 1 year ago

allanviana-logcomex commented 1 year ago

Summary

Idk if there is a issue about this. When I tried to solve this issue, I saw that maybe the PR #7 that tried to fix .br domains, was accepted even though it didn't work.

So I figure out that the problem is in the expiry date check, which does not check correctly when the variable was only initialized (in this case has a value less than 0).

Pay attention

This PR as it is, because how .br and .ua domains is trying to get expiry date. So maybe it's better to approve PR #8.

Checklist

TwiN commented 1 year ago

My bad, I already fixed the test with 9f681448ab8ddddba0ffef04ece33c02d25c6cde

Still, after the change, the tests worked on #8 so 🙌

Thank you for your contribution!