KARACHI (Reuters) - In the currency market, the rupee ended firmer at 84.51/57 to the dollar, compared with Mondays close of 84.68/78. Dealers said there were few import payments in the market, and portfolio inflows had provided some support over recent days. According to official data, foreigners have bought shares worth a net $31.86 million this month. The rupee ended at an all-time closing low last week and hit an all-time low of 85.15 last month. Dealers said the rupee may firm in the event of more selling by exporters and if external flows started to come in. But the medium-term outlook remained weak. The rupee has lost 0.25pc against the dollar this year after losing 6.17pc last year and a 22.12pc slide in 2008.