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

960, 961 & 9620 & 9624 have been assigned to GS1 UK for GTIN-8 allocation #162

Open
stereobooster opened this issue Dec 11, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@stereobooster
Copy link

As far as I can see from the source code it doesn't take into account this edge case

960, 961 & 9620 & 9624 have been assigned to GS1 UK for GTIN-8 allocation. 9625 & 9626 have been assigned to GS1 Poland for GTIN-8 allocation.

From https://www.gs1.org/standards/id-keys/company-prefix

@jodal
Copy link
Owner

jodal commented Dec 18, 2022

You're absolutely right. The current implementation only loops through data similar to the table at https://www.gs1.org/standards/id-keys/company-prefix and returns the first match, in this case Global Office - GTIN-8. To support these four edge cases, I think it needs to be rewritten to compare with the longest possible prefixes first.

I'm curious, what's your use case for knowing that these are not only Global Office - GTIN-8 but something more specific, like GS1 UK - GTIN-8?

@jodal jodal added the enhancement New feature or request label Dec 18, 2022
@stereobooster
Copy link
Author

I don't have specific use case in my mind. I read through code-base and noticed it...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants