function convertRate(rate) {
    return Object.keys(rate.quotes).reduce(
      (acc, pair) => {
        const code = pair.substr(3, 3);
        acc[code] = rate.quotes[pair];
        return acc;
      },
      { [BASE]: 1 }
    );
  }
Convert response from API service to internal rate object.

@param {object} dict { ..., quotes: { USDUSD: 1, USDEUR: 0.834499, ... } }
@return {object} dict { USD: 1, EUR: 0.834499, ... }