def parse(self, response):
        state_urls = response.xpath('//li[@class="col-sm-12 col-md-4"]/a/@href').extract()
        is_store_details_urls = response.xpath('//a[@class="store-details-link"]/@href').extract()

        if not state_urls and is_store_details_urls:
            for url in is_store_details_urls:
                yield scrapy.Request(response.urljoin(url), callback=self.parse_store)
        else:
            for url in state_urls:
                yield scrapy.Request(response.urljoin(url))