If you contribute to an open-source project, your code is already released. What GPL prevents is a competitor using your code released as open-source and turning it into a competing proprietary product. Apache licenses allow that. if you fear your competitors may use your code, contributing to an Apache-licensed project is infinitely worse because then your competitors are allowed to derive their work from your contributions and never share back, something GPL would prevent.