diff --git a/lib/uk_planning_scraper.rb b/lib/uk_planning_scraper.rb index b7aaa2b..34abd18 100644 --- a/lib/uk_planning_scraper.rb +++ b/lib/uk_planning_scraper.rb @@ -5,4 +5,6 @@ require 'uk_planning_scraper/northgate' require 'logger' module UKPlanningScraper + class SystemNotSupportedError < StandardError + end end diff --git a/lib/uk_planning_scraper/authority.rb b/lib/uk_planning_scraper/authority.rb index 2df77a0..18e99ab 100644 --- a/lib/uk_planning_scraper/authority.rb +++ b/lib/uk_planning_scraper/authority.rb @@ -45,7 +45,7 @@ module UKPlanningScraper apps = self.scrape_northgate(authority.url, params, options) else # Not supported - raise "Planning system not supported for #{@name} at URL: #{@url}" + raise SystemNotSupportedError.new("Planning system not supported for #{@name} at URL: #{@url}") end # Post processing