Sam Allardyce admits his West Ham side had to dig in defensively on route to their 2-0 victory at Burnley in the Capital One Cup.