Could just be because the application was written by a less experienced programmer, or even outsourced?
I cannot describe the shock when I realized what information an attacker could have gained in a window of 6 months the bug was active.
All of this code was written by experienced programmers, it's just that nobody ever wrote any tests to ensure the fancy security code was still in place.