Earlier quoted context omitted.
"Can't understand their accent" _is_ discriminatory. Please don't ever recommend against a candidate for that. Companies are definitely taking the easy way out. The reality is that most of them don't have a good hiring process, aren't consistent about hiring decisions, and tend to choose based on factors that have nothing to do with the job they're hiring for.
Yes, It is discriminatory. So ? Not able to code is also discriminatory to someone who don't know how to code.
It is one of the hallmarks of union labor management. It is one reason why private labor has a competitive advantage.