Please add tests for this function, testing:
 * with valid locale not in `AVAILABLE_LANGUAGES`
 * with valid locale in `AVAILABLE_LANGUAGES`
 * with invalid locale