Computing the mass shift of Wilson and staggered fermions in the lattice Schwinger model with matrix product states