-
Notifications
You must be signed in to change notification settings - Fork 360
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
Added barcode extension to core #252
Conversation
src/Faker/Core/Barcode.php
Outdated
{ | ||
$code = Extension\Helper::numerify(str_repeat('#', $length - 1)); | ||
|
||
return $code . \Faker\Calculator\Ean::checksum($code); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I maybe would have done this with sprintf to keep it more readable and a bit more secure overall.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've changed this now.
Thanks! Left some small comments but overall it looks good to me 👍 |
^^ Wrong button sorry |
Thanks |
Thanks @pimjansen! |
* add barcode to core * add barcode to core
What is the reason for this PR?
Barcode extension is not yet in core.
Author's checklist
Summary of changes
Like #232 only for barcodes - added barcode extension to core.
Review checklist