X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/e1b205913c9afd6b41684add7308cef4613112e2..b91b514cf22f04910c83b6dcc254908ed37d7413:/lib/osm.rb diff --git a/lib/osm.rb b/lib/osm.rb index 3ddf10f98..82fc835b4 100644 --- a/lib/osm.rb +++ b/lib/osm.rb @@ -46,6 +46,13 @@ module OSM { :text => "The supplied changeset has already been closed", :status => :conflict } end end + + # Raised when a change is expecting a changeset, but the changeset doesn't exist + class APIChangesetMissingError < APIError + def render_opts + { :text => "You need to supply a changeset to be able to make a change", :status => :conflict } + end + end # Raised when the provided version is not equal to the latest in the db. class APIVersionMismatchError < APIError @@ -57,7 +64,7 @@ module OSM def render_opts { :text => "Version mismatch: Provided " + provided.to_s + - ", server had: " + latest.to_s, :status => :bad_request } + ", server had: " + latest.to_s, :status => :conflict } end end