Jes Staley is leaving the bank following an investigation into his links to sex offender Jeffrey Epstein.