The Dirac Operator $D$ is defined by \begin{equation}\tag{1} D=i\gamma^a\nabla_a=i\gamma^a\nabla_{e_a}=i\underbrace{\gamma^a{e_a}^\mu}_{=\gamma^\mu}\nabla_{\partial_\mu}=i\gamma^\mu\nabla_\mu=i\gamma^\mu(\partial_\mu+\omega_\mu+A_\mu) \end{equation} and \begin{equation} \omega_a=-\frac{1}{4}\omega_{abc}\gamma^{bc}\psi={e_a}^\mu\omega_\mu. \end{equation} However, in his derivation of the Atiyah Singer Index theorem$^1$, Fujikawa (chapter $5.5$ of Path Integrals and Quantum Anomalies) assumes \begin{equation} D=i\gamma^\mu\nabla_\mu=i\gamma^\mu(\partial_\mu+A_\mu). \end{equation} One might think that Fujikawa's $D$ is simply another operator, but Nakahara - who derives the same equation in section $13.2.1$ (Fujikawa's method) - says that the spin connection "plays no role" under certain assumptions:
We compactify the space in such a way that the geometry (the spin connection) plays no role. For example, this can be achieved by compactifying $\mathbf{R}^4$ to $S^4=\mathbf{R}^4\cup\{\infty\}$, for which the Dirac genus $\hat{A}(TM)$ is trivial.
I know that $S^n\cong\mathbf{R}^n\cup\{\infty\}$, but I don't see why this implies that the spin connection "plays no role".
$^1$ By the "Atiyah Singer Index theorem" I mean the equation \begin{equation} \mathrm{ind}\,D_+=-\frac{1}{8\pi^2}\int_M\mathrm{tr}(F_{ij}F_{kl})\epsilon^{ijkl}\cdot\omega, \end{equation} where $M$ is a $4$-dimensional Riemannian manifold with euclidean signature and $\omega$ is the volume form. (I am aware of the fact that $D\colon\Gamma(M,S\otimes E)\to\Gamma(M,S\otimes E)$ is a Fredholm operator and that $(1)$ is only valid after the choice of a local gauge - here we assume that $E$ is the the associated vector bundle induced by the adjoint representation.)