Fix multiple bugs in the recent i18n module changes