def station_record_to_dict(self, record):
    postcode = ' '.join(record['address'].split(' ')[(- 2):])
    point = self.extract_geometry(record, self.geom_type, self.get_srid())
    if ((record['district'], postcode) in self.seen):
        return None
    else:
        self.seen.add((record['district'], postcode))
    return {'internal_council_id': record['psnumber'], 'polling_district_id': record['district'], 'address': record['address'], 'postcode': postcode, 'location': point}
def station_record_to_dict(self, record):
    postcode = ' '.join(record['address'].split(' ')[(- 2):])
    point = self.extract_geometry(record, self.geom_type, self.get_srid())
    if ((record['district'], postcode) in self.seen):
        return None
    else:
        self.seen.add((record['district'], postcode))
    return {'internal_council_id': record['psnumber'], 'polling_district_id': record['district'], 'address': record['address'], 'postcode': postcode, 'location': point}