-
Notifications
You must be signed in to change notification settings - Fork 85
ModelAccessorValidator::validate always fails in method createForwardingAddress of PaymentForwardClient #3
Comments
Thanks for your feedback @rtarnaud. I will check it asap. |
Hi @rtarnaud could you post you sdk_config.ini file in the section?:
It seems you could have an invalid option in that section. Anyway I think I should return true at the end of the method. I think I am going to change it and I will return an exception if |
Hi @josecelano, As far as I understand, there should be a configuration file sdk_config.ini in the library in order to provide various settings, validation.level being one of them. Regarding your proposed change, I think you are right: ModelAccessorValidator::validate checks whether the called method actually exists which is unusual. It is rather up to the API user to know what methods are available in the API, hence this validation could be considered as an optional level of safety. |
Sorry for the delay @rtarnaud I have been very busy. Regarding config file you can put it when you want. You only have to define this define Samples in this library use a bootstrap file and it contains both ways for setting up the library: config array and config file. Define is in this line: https://github.com/blockcypher/php-client/blob/master/sample/bootstrap.php#L90 |
Hi,
I think there's a problem with ModelAccessorValidator::validate, especially the first line:
$mode = BlockCypherConfigManager::getInstance()->get('validation.level');
$mode is set to an empty array and therefore, the subsequent check in the method fail and lead to returning false.
Have you noticed that problem too?
Thanks!
The text was updated successfully, but these errors were encountered: