fixed guard regex to support locales with more than two letters (e.g.: zh-TW, it-CH)