Why can we use the equation of motion to calculate the amplitude in "Quantum Field Theory"? I am reading the chapter on electron-proton scattering from "Quantum Field Theory in a Nutshell". The author calculates the amplitude of the electron-proton scattering (up to the second order). The Feynman diagram used in this calculation is

We start by using the massive spin 1 boson as an exchange, and hope to get rid of the mass later. Let the mass of the boson be $\mu$
Using the Feynman rules, we obtained the amplitude to be
$$\mathcal{M}(P,P_N) = (-ie)(ie)\frac{i}{(P-p)^2-\mu^2}\left(\frac{k_\mu k_\nu}{\mu^2}-\eta_{\mu\nu}\right)\bar{u}(P)\gamma^\mu u(p)\bar{u}(P_N)\gamma^\nu u(p_N).$$
He claims that the term $k_\mu k_\nu$ will just disappear because
$$k_\mu \bar{u}(P)\gamma^\mu u(p) = (P-p)_\mu \bar{u}(P)\gamma^\mu u(p) = \bar{u}(P)(\not P - \not p) u(p)=\bar{u}(P)(m - m) u(p)=0.$$
However, the last equation follows the Dirac equation, which is the equation of motion of the electron. The point that I do not understand is, how can we use the equation of motion in the quantum field theory? Clearly, the equation of motion comes from minimising (extremising) the action, which leads to the classical field rather than quantum field.
 A: The spinor $u(p)$ satisfies the equation $\not{\!p} u(p) = m\, u(p)$ by construction from the expansion of the Dirac spinor $\psi(x)$ in solutions of the Dirac equation. The quantisation (in the canonical approach) happens by making the coefficients of these spinors operators. These two things should not be confused with one another.
The whole point of canonical quantisation is to  expand the solution of the classical equation of motion in plane waves and make the coefficients operators. For scalar fields that is straightforward and it is basically the harmonic oscillator. For spin one field you need an extra $\epsilon^\mu$ to describe the polarisation of the field (the degrees of freedom of $A^\mu$). These polarisations don't become operators, it is the coefficients $a$ and $a^\dagger$. For spin 1/2 you need to attach a spinor to the plane wave (because a fermion is described by a spinor). But these spinors need to satisfy the equations $\not{\!p} u(p) = m\, u(p)$ for the expansion to satisfy the Dirac equation. Once more these are not promoted to operators after quantisation. It is the coefficients $a, a^\dagger, b$ and $b^\dagger$ that become operators.
