def refresh_sitemap
      if self.published
        if Rails.env == 'production' && ENV["CONFIG_FILE"]
          SitemapGenerator::Interpreter.run(config_file: ENV["CONFIG_FILE"])
          SitemapGenerator::Sitemap.ping_search_engines 
        end
      end
    end
def refresh_sitemap
      if self.published
        if Rails.env == 'production' && ENV["CONFIG_FILE"]
          SitemapGenerator::Interpreter.run(config_file: ENV["CONFIG_FILE"])
          SitemapGenerator::Sitemap.ping_search_engines 
        end
      end
    end
Refreshes the sitemap and pings the search engines