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

Returns wrong bank name for bic PBNKDEFFXXX #16

Open
rvasquez-flip4new opened this issue Nov 10, 2017 · 5 comments
Open

Returns wrong bank name for bic PBNKDEFFXXX #16

rvasquez-flip4new opened this issue Nov 10, 2017 · 5 comments

Comments

@rvasquez-flip4new
Copy link

Hi,

with v0.3.4 the correct bank name for bic PBNKDEFFXXX should be "Postbank Frankfurt" (see http://bank-code.net/swift-code/PBNKDEFFXXX.html).

[1] pry(main)> iban = Ibanizator.iban_from_string("DE09500100600175890604")
=> #<Ibanizator::Iban iban_string="DE09500100600175890604">
[2] pry(main)> iban.extended_data.bic
=> "PBNKDEFFXXX"
[3] pry(main)> bic = iban.extended_data.bic
=> "PBNKDEFFXXX"
[4] pry(main)> bank = Ibanizator.bank_db.bank_by_bic(bic)
=> #<Ibanizator::Bank bic="PBNKDEFFXXX" name="Postbank Leipzig" bank_code="86010090">
[5] pry(main)> bank.name
=> "Postbank Leipzig"
@zaknafain
Copy link
Collaborator

Hey,

the problem is the ordering. I fixed it a while ago in my fork.
Feel free to use it.

@zaknafain
Copy link
Collaborator

Hm ... I had a second look into this. All Postbanks have the same BIC, so finding a specific bank via this BIC is not possible.

@phoet
Copy link
Contributor

phoet commented Apr 26, 2018

@zaknafain wouldnt it make sense to return a list of banks instead?

@JGantner
Copy link
Contributor

@phoet that would make sense in my optinion but would require an API change that would break some client code. So this change should be planned properly.

@phoet
Copy link
Contributor

phoet commented May 25, 2018

indeed. i don't know how much adoption this gem has, i would probably go the easy way of releasing a new mayor version with a note in the changelog.

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

No branches or pull requests

4 participants