Commit graph

91 commits

Author SHA1 Message Date
John Firebaugh
261862a8dd Send appropriate Vary header
Fixes an issue where the XHR response was sometimes
displayed when navigating back to a pushState
based history entry rather than the full page.
2013-11-06 13:16:48 -08:00
John Firebaugh
a56d1036d5 pushState based navigation between map-based layouts 2013-10-13 14:46:08 -07:00
Tom Hughes
0e9e6e6f8f Upgrade to http_accept_language 2.x 2013-09-24 20:22:44 +01:00
John Firebaugh
8dc16bd8db Make iD default editor
Make iD the default editor for all users that have not specified
a preferred editor, except fall back to P2 on IE.
2013-08-15 16:36:18 -07:00
Tom Hughes
b2c42d5521 Fix detection of timeouts 2013-08-12 17:33:18 +01:00
Tom Hughes
3880ac5de8 Replace :nothing => true with :text => ""
Using `:nothing => true` confusingly actually causes a single space
to be sent as the content by rails.
2013-07-19 11:14:55 +01:00
Tom Hughes
2dc7c505fd Remove remaining action cache usage and related infrastructure 2013-06-25 17:47:54 +01:00
Tom Hughes
720c8d0e35 Improve locale selection for Potlatch 2 and iD 2013-05-08 22:28:41 +01:00
Tom Hughes
b0a84cf1bf Explicitly set text/plain as the type for error responses 2013-04-24 17:46:45 +01:00
Tom Hughes
7f598ab412 Merge branch 'master' into notes
Conflicts:
	Gemfile.lock
	app/views/diary_entry/list.html.erb
2013-04-08 22:34:37 +01:00
Matt Amos
3822e8de77 Added database, API and GPX status to capabilities. 2013-04-02 15:05:20 +01:00
Tom Hughes
97e0d5ad1f Add a new write_notes permission needed for OAuth access to notes 2013-03-28 18:50:18 +00:00
Tom Hughes
e8d32637c1 Add javascript OAuth support 2013-03-28 00:34:09 +00:00
Tom Hughes
c2c2535b73 Make sure we always read the body of a PUT or POST request
Unfortunately if a PUT or POST request that has a body fails to
read it then Apache will sometimes fail to return the response it
is given to the client properly, instead erroring:

  https://issues.apache.org/bugzilla/show_bug.cgi?id=44782

To work round this we call rewind on the body for every request using
a filter, which forces it to be fetched from Apache into a file.
2012-11-01 12:45:37 +00:00
Tom Hughes
3ef02b86f0 Revert "Add a newline to the end of the body when reporting an error"
This reverts commit 59c97f4866.
2012-11-01 12:42:47 +00:00
Tom Hughes
59c97f4866 Add a newline to the end of the body when reporting an error
There seems to be some sort problem with ruby 1.9 where a response
body that is a single line with no newline causes the response not
to be sent properly.
2012-11-01 09:13:43 +00:00
Tom Hughes
95fa893163 Make it easier to test alternative locales
Allow a locale=xx parameter in the URL to select the locale.
2012-10-26 21:41:03 +01:00
Tom Hughes
fbabed694b Improve blocks on/by links on user pages
All block related links are now only shown if the user has given
or received any blocks, and include a count of active blocks.
2012-08-10 08:27:37 +01:00
Tom Hughes
6bafc93435 Error in a changeset feed is requested for a non-existent user 2012-05-01 20:40:59 +01:00
Matt Amos
1f9301e2e2 Better comments in application controller logic 2012-04-05 13:52:07 +01:00
Matt Amos
851de28303 Added redactions resource 2012-04-05 13:50:15 +01:00
Matt Amos
67182f824e Fixing review comments
Added scoping for unredacted items, cleaned up authorization and
railsified old_node_controller.
2012-04-05 13:46:40 +01:00
Tom Hughes
151626d019 We no longer need to disable sessions when the database is offline 2012-04-02 18:42:14 +01:00
Tom Hughes
311f7ddd6e Factor out common code for looking up users 2012-03-21 22:22:33 +00:00
Tom Hughes
a9824dbc2e Use one "no_such_user" view everywhere 2012-03-21 21:47:09 +00:00
Tom Hughes
e1d873cde9 Add functional tests for user blocks
Also fixes various issues in the code discovered while writing
the tests, and adds some named routes for user blocks.
2012-03-19 11:26:02 +00:00
Tom Hughes
232e04ab9b Use a consistent host name in cache keys 2012-03-04 10:27:34 +00:00
Tom Hughes
af13c42322 Refactor session persistence code 2012-02-26 21:44:17 +00:00
Tom Hughes
e2b185133e ActionController::UnknownAction is now AbstractController::ActionNotFound 2012-02-15 17:48:16 +00:00
Tom Hughes
8afc736536 Revert "Log locale selection"
This reverts commit 101ee6ade2.
2012-02-14 15:47:21 +00:00
Tom Hughes
101ee6ade2 Log locale selection 2012-02-14 14:57:29 +00:00
Tom Hughes
63cc3c195a Try really hard to find out if the real exception was a timeout
Helpfully rails manages to wrap the actual exception that occurred
in at least one, and sometimes two further levels of exception, one
of which does preserve the original exception except as text.
2012-01-07 15:03:25 +00:00
Tom Hughes
55dda7b184 Recognise wrapped timeout exceptions properly 2012-01-07 14:16:39 +00:00
Tom Hughes
00a605a2a8 Use Timeout if SystemTimer isn't loaded 2012-01-06 09:11:23 +00:00
Tom Hughes
7e66fcbb1b Log any session that is reset due to a username mismatch 2011-11-24 09:42:04 +00:00
Tom Hughes
7b89dc6349 Make OAuth work again 2011-11-16 21:13:25 +00:00
Tom Hughes
cbd687d0b1 Explicitly select the default locale if we have no better ideas 2011-11-16 09:21:23 +00:00
Tom Hughes
4408416b62 Add some logging to help diagnose changeset feed locale issue 2011-11-16 08:56:35 +00:00
Tom Hughes
9e2132b83d Don't reset the session when the token refers to an invalid user
During account creation it is quite normal for the token in the
session to refer to a user that is not active yet.
2011-11-14 09:42:59 +00:00
Tom Hughes
5bc3054d61 Store the username in a cookie and use it to validate the session 2011-11-14 09:42:59 +00:00
Tom Hughes
c485ae3249 Fix object_id warning 2011-11-14 09:42:58 +00:00
Tom Hughes
2c837d896d Make database offline mode work 2011-11-14 09:42:56 +00:00
Tom Hughes
96c22b169a Get OAuth working, including a hack for Potlatch 2011-11-14 09:42:55 +00:00
Tom Hughes
f0d7c4a8d6 Rework expansion of HTTP status code to work with rails 3 2011-11-14 09:42:48 +00:00
Tom Hughes
7f556f94f1 Temporary fix for postgres enums pending rails 3.0.4 2011-11-14 09:42:46 +00:00
Tom Hughes
1e13e6ae2d Update oauth support for rails 3 version of oauth plugin 2011-11-14 09:42:45 +00:00
Tom Hughes
226c41be69 Update ActiveRecord queries to use arel 2011-11-14 09:42:44 +00:00
Tom Hughes
7d45c2fd3c Replace request.request_uri with request.fullpath 2011-11-14 09:42:42 +00:00
Tom Hughes
c9fa49c994 Update to rails 3 2011-11-14 09:42:40 +00:00
Tom Hughes
59a49a6ef5 Fix problems with database offline mode 2011-06-23 08:30:44 +01:00