Fix formatting of locale codes