Ticket #1742 (closed enhancement: fixed)
Naming of a new package/group can clash with a route
Reported by: | ross | Owned by: | ross |
---|---|---|---|
Priority: | trivial | Milestone: | ckan-sprint-2012-03-19 |
Component: | ckan | Keywords: | [1d][a:0.5d] |
Cc: | Repository: | ckan | |
Theme: | none |
Description
It is possible to create a group or a dataset called new, or edit, which will then be inaccessible as it is blocked by the existing routes with those names.
We should maintain a list of invalid names in the verification that happens behind the scenes in the UI.
Change History
Note: See
TracTickets for help on using
tickets.
Potentially valid diff, needs test + patch when I have time.
--- a/ckan/controllers/api.py +++ b/ckan/controllers/api.py @@ -592,6 +592,8 @@ class ApiController?(BaseController?):
+ if slug in ['new', 'edit', 'search']: + return self._finish_ok( dict(valid=False) )