Brazil had a trade surplus of $2.379 billion in July, government data showed on Monday, in line with market estimates for a surplus of $2.3 billion.

The country posted a trade surplus of $4.5 billion in June.

After running a deficit for most of 2015, Brazil’s trade balance has turned positive as a weaker local currency bolsters exports and a shrinking economy weighs on imports.

The government has raised its trade surplus estimate to up to $10 billion this year from about $5 billion. The major commodity exporter recorded its first trade deficit in 14 years in 2014 after the price of key products such as iron ore and soy fell sharply.