Object parameters should be type hinted

More information: https://insight.symfony.com/what-we-analyse/php.object_parameter_not_type_hinted

  1. * @throws Exception\ProviderNotFoundException
  2. * @throws Exception\RateNotFoundException
  3. * @throws Exception\CurrencyNotFoundException
  4. * @return float
  5. */
  6. public function convert($from, $to, $value, $provider = null, $rateDate = null)

    The parameter provider, which is an object, should be typehinted.

    Time to fix: about 1 hour
    Open Issue Permalink
    Last edited by Andrey Red
  7. {
  8. $to = $this->getCurrency($to);
  9. $from = $this->getCurrency($from);
  10. $providers = $provider === null ? $this->providerFactory->getAll() : [$this->providerFactory->get($provider)];
  11. $providers = array_filter($providers);
  • mazahaca

    Ignored on Sun, 15 Mar 2015 20:09:52 GMT