Barcelona fought back from a goal down to beat Leganes courtesy of goals from Luis Suarez and Arturo Vidal.
Youssef En-Nesyri gave the host the lead in the first half with a stunning strike, Barcelona struggled to create any clear cut chance as Leganes ended the first half victorious.
The visitors improved after the restart as Luis Suarez restored parity with a glancing header.
Antoine Griezmann struggled once again and he was replaced by Arturo Vidal.
Vidal scored the winning goal to give Barcelona the maximum points.
Barcelona have lost three times away from home this season.
The Blaugrana struggled to find their rhythm as question marks remain on Erneste Valverde