re-write function get_exchange_rate