fixes non-country two letter codes messing up json and html generation