'Returns country name for given code or id from L0 locations.
The key can be either location id or country code, as specified
by key_type.'

@staticmethod
def get_country(key, key_type='id'):

    if key:
        if current.gis.get_countries(key_type):
            if (key_type == 'id'):
                return current.session.gis.countries_by_id[key]
            else:
                return current.session.gis.countries_by_code[key]
    return None
