Fixes the exception thrown when the provider list for a given language is empty/undefined.
Improve readability of fix.
Further improvde readability by grouping the first part of the expression together.
Merge pull request #10068 from Mark-Simulacrum/hotfix-codeinspection

Fixes the exception thrown when the provider list for a given language is undefined.