dmitrirussu / php-sepa-xml-generator

SEPA SDD XML Generator recommended to see. PHP SEPA XML Generator, (Single Euro Payments Area ISO20022 SDD V1_0 20122009) (SEPA)(PHP5)
https://github.com/dmitrirussu/PHP-SEPA-XML-GENERATOR
MIT License
53 stars 36 forks source link

Fixed type error causing crash on HHVM #25

Closed gmaiztegi closed 9 years ago

gmaiztegi commented 9 years ago

HHVM's dom_import_simplexml() enforces type restriction by accepting only a SimpleXMLElement, and throwing error otherwise. I guess regular PHP would accept a DOMElement with, possibly, a warning.

This removes the previous conversion so the argument passed to dom_import_simplexml() in XMLGenerator is a propper SimpleXMLElement.

dmitrirussu commented 9 years ago

I understood your point of view, But there are not node of DomElement which I Pass to dom_import_simplexml(), Strange why you receive warning on HHVM.

I did some test cases I can accept your improvement. but anyway is strange your problem, if you can to put here the type of warning which you had.