[openstreetmap/openstreetmap-website] Fixes "new trace" validation error (#1938)

Jamie Guthrie notifications at github.com
Wed Jul 25 00:55:24 UTC 2018


At the moment if you try and upload a trace without setting a `description`, then the page just hangs.

Now it redirects back to `traces/new` with full validation errors.

- Funnily enough, if a GPX file was not selected, then the full validation errors were shown, but if a GPX file was selected for upload, then any further validation errors were not picked up, as a general `StandardError` was thrown and logged, but wasn't being properly handled on the front end.

Now it all works
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/1938

-- Commit Summary --

  * No trace description now redirects to /new

-- File Changes --

    M app/controllers/traces_controller.rb (1)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/1938.patch
https://github.com/openstreetmap/openstreetmap-website/pull/1938.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/1938
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20180724/7fb0f31f/attachment.html>


More information about the rails-dev mailing list