diff --git a/config/routes.rb b/config/routes.rb index d6a135b3dd..bf8ac6aa01 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -124,4 +124,9 @@ Openfoodnetwork::Application.routes.draw do # Mount Spree's routes mount Spree::Core::Engine, :at => '/' + + # Errors controller + match '/404' => 'errors#not_found', via: :all + match '/500' => 'errors#internal_server_error', via: :all + match '/422' => 'errors#unprocessable_entity', via: :all end diff --git a/public/404.html b/public/404.html deleted file mode 100644 index 4e42e63b73..0000000000 --- a/public/404.html +++ /dev/null @@ -1,41 +0,0 @@ - - - - The page you were looking for doesn't exist (404) - - - - - -
- -

Oops! Page not found.

- Please try again -

This might be a temporary problem. Please click the back button to return to the previous screen or go back to Home and try again.

- Contact support -

If the problem persists or is urgent, please tell us about it. Find our contact details from the global Open Food Network Local page.

-

It really helps us if you can give as much detail as possible about what the missing page is about.

-
- - diff --git a/public/422.html b/public/422.html deleted file mode 100644 index c6a93d7ab6..0000000000 --- a/public/422.html +++ /dev/null @@ -1,38 +0,0 @@ - - - - The change you wanted was rejected (422) - - - - - -
- -

The change you wanted was rejected. Maybe you tried to change something you don't have access to. -

Return home

-

-
- - - diff --git a/public/500.html b/public/500.html deleted file mode 100644 index b3dd25194a..0000000000 --- a/public/500.html +++ /dev/null @@ -1,43 +0,0 @@ - - - - We're sorry, but something went wrong (500) - - - - - -
- -

We're sorry, but something went wrong.

- Please try again -

This might be a temporary problem. Please click the back button to return to the previous screen or go back to Home and try again.

- We're on it -

If you have seen this problem before, we probably already know about it and are working on a fix. We record all the errors that come up.

- Contact support -

If the problem persists or is urgent, please tell us about it. Find our contact details from the global Open Food Network Local page.

-

It really helps us if you can give as much detail as possible about what you were doing when this error occurred.

-
- -