'If `shelf` is defined, validate that the FeedItem\'s `carrier` and
`region` match the `carrier` and `region on `shelf`.'

def validate_shelf(self, shelf_id):

    if shelf_id:
        shelf = FeedShelf.objects.get(pk=shelf_id)
        carrier = CARRIER_CHOICE_DICT[shelf.carrier]
        if (self.initial_data.get('carrier') != carrier.slug):
            raise serializers.ValidationError('Feed    item    carrier    does    not    match    operator    shelf    carrier.')
        region = REGIONS_CHOICES_ID_DICT[shelf.region]
        if (self.initial_data.get('region') != region.slug):
            raise serializers.ValidationError('Feed    item    region    does    not    match    operator    shelf    region.')
    return shelf_id
