Headphone Jack not recognized [ASUS Zephyrus M GU502GW]

The issue on Zephyrus models appeared before changes were made that broke the sound on non-Zephyrus models; Moreover, for Zephyrus models, connected headphones are not detected at all, and other models are detected, but without sound. These are different problems.

I did not send any reports (I do not have an account on Bugzilla), and the one on Bugzilla does not contain information about the source of the problem that I found, so it will take an extremely long time to fix, if at all.