Code Duplication    Length = 3-3 lines in 2 locations

src/RunOpenCode/ExchangeRate/Repository/DoctrineDbalRepository.php 2 locations

@@ 190-192 (lines=3) @@
187
                ]
188
            );
189
190
            if (0 === count($result)) {
191
                throw new ExchangeRateException(sprintf('Could not fetch rate for rate currency code "%s" and rate type "%s" on date "%s".', $currencyCode, $rateType, $date->format('Y-m-d')));
192
            }
193
194
            $this->identityMap[$key] = $this->buildRateFromTableRowData($result[0]);
195
        }
@@ 217-219 (lines=3) @@
214
            ]
215
        );
216
217
        if (0 === count($result)) {
218
            throw new ExchangeRateException(sprintf('Could not fetch rate for rate currency code "%s" and rate type "%s" on date "%s".', $currencyCode, $rateType, $date->format('Y-m-d')));
219
        }
220
221
        $rate = $this->buildRateFromTableRowData($result[0]);
222
        $key = $this->getRateKey($rate->getCurrencyCode(), $rate->getDate(), $rate->getRateType(), $rate->getSourceName());