-
Notifications
You must be signed in to change notification settings - Fork 52
Authorize singleton resources #38
Comments
I haven't thought much about the singleton use case. To solve this, the first, most pragmatic solution would be to just to use conventional resource URLs like However, it would be nice to support a non-conventional URL structure. One solution could be a The other solution - that you suggested - is to allow the user to specify a custom I think the best thing might be to replace the ecto methods in Line 298 in ff76baa
I'll look into it. Also, PRs are always welcome :). |
Work in progress PR here #39. |
Closing this, since the conversation is dead. |
I would like to use the
:authorize_resource
plug in a controller for a singleton resource (/user
).This means that there is no
:id
parameter for theshow
action. However canary always tries to fetch the resource for theshow
action by id. I'm not sure what a good solution would be? Maybe allow overwriting thefetch_resource/2
method?The text was updated successfully, but these errors were encountered: