jkeen / tracking_number_data

Shared data for cross platform tracking number detection
MIT License
114 stars 39 forks source link

Correct serial number group for DHL express numbers #100

Closed jkeen closed 1 year ago

jkeen commented 1 year ago

In working through some of the information from #99 it appears there was an error in the DHL tracking number regex.

For checksum calculations to work, the <SerialNumber> group should contain only numbers, but For DHL Express numbers that contained letters as well. The ruby client didn't error due to this since in ruby "JD000000".to_i == 0, but in other clients this caused an issue.

This PR corrects that.

Additionally, it turns out with that correction that "JVGL0999999990" does not pass mod7 validation, so I have split those oddball J* dhl numbers into their own group without validation until more information is found about them.

github-actions[bot] commented 1 year ago

:tada: This PR is included in version 1.6.1 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: