jschaedl / iban-validation

:bank: A small library for validating International Bank Account Numbers (IBANs)
MIT License
88 stars 19 forks source link

Migrate from jschaedl/iban #11

Closed davidvandemaele closed 5 years ago

davidvandemaele commented 5 years ago

When I migrate to the new iban-validation package and try to validate an iban number, I get the following error:

: Uncaught Error: Class 'Symfony\Component\Yaml\Parser' not found in lib/external/packages/symfony/yaml/Yaml.php:77 Stack trace:

0 lib/external/packages/jschaedl/iban-validation/src/Swift/RegistryLoader.php(41): Symfony\Component\Yaml\Yaml::parse('AD:\n country...')

1 lib/external/packages/jschaedl/iban-validation/src/Swift/Registry.php(37): Iban\Validation\Swift\RegistryLoader->load()

2 lib/external/packages/jschaedl/iban-validation/src/Validator.php(84): Iban\Validation\Swift\Registry->__construct()

3 lib/model/Supplier.php(40): Iban\Validation\Validator->__construct()

xabbuh commented 5 years ago

Does the file lib/external/packages/symfony/yaml/Parser.php exist? How is your autoloading configured?

davidvandemaele commented 5 years ago

Yes it did. If I tried to do the same via commandline, I got the same error. If I included the Parser class and parsed the string, it worked. I've uninstalled the iban-validation package and gave it another try. Now it is working.