Lisandro Martinez’s deflected 78th-minute strike earned Manchester United a hard-fought and much-needed victory at Fulham.