Skip to content

v0.7.0

Compare
Choose a tag to compare
@calebkleveter calebkleveter released this 17 May 22:22
· 33 commits to master since this release
7530c79

This Route is Rather Restricting

And it should be, considering admins should be the only ones supposed to access the data. And you can add this functionality yourself, with RouteRestrictionMiddeware:

route.group(RouteRestrictionMiddleware(
    restrictions: [
        RouteRestriction(.DELETE, at: "users", User.parameter, allowed: [.admin, .moderator]),
	...
    ],
    parameters: [User.routingSlug: User.resolveParameter]
))