Added the fallback of getLocale.