It’s a security issue in the sense that it defeats the signing scheme: rather than negotiating the key out-of-band, the user is trusting the thing they’re trying to verify to supply the key. In other words “trust me because I’m signed, and also trust me to give you the key I’m signed with.”
On the other hand, approximately nobody actually verifies git commit signatures, so it doesn’t matter all that much :-)