Fix pygment lexer 500 errors when an alias is used instead of a name.

Fixes the following errors:
https://github.com/gitlabhq/gitlabhq/issues/4074
https://github.com/gitlabhq/gitlabhq/issues/3257
https://github.com/gitlabhq/gitlabhq/issues/4015

and problem on GitLab Cloud