gateway: return project if the project is public

If the project is public don't require the user to be logged in to show the
project.
This commit is contained in:
Simone Gotti 2019-07-12 23:41:34 +02:00
parent f61a6068c2
commit 5483620fb0
1 changed files with 1 additions and 1 deletions

View File

@ -235,7 +235,7 @@ func (g *Gateway) Run(ctx context.Context) error {
apirouter.Handle("/projectgroups/{projectgroupref}", authForcedHandler(updateProjectGroupHandler)).Methods("PUT") apirouter.Handle("/projectgroups/{projectgroupref}", authForcedHandler(updateProjectGroupHandler)).Methods("PUT")
apirouter.Handle("/projectgroups/{projectgroupref}", authForcedHandler(deleteProjectGroupHandler)).Methods("DELETE") apirouter.Handle("/projectgroups/{projectgroupref}", authForcedHandler(deleteProjectGroupHandler)).Methods("DELETE")
apirouter.Handle("/projects/{projectref}", authForcedHandler(projectHandler)).Methods("GET") apirouter.Handle("/projects/{projectref}", authOptionalHandler(projectHandler)).Methods("GET")
apirouter.Handle("/projects", authForcedHandler(createProjectHandler)).Methods("POST") apirouter.Handle("/projects", authForcedHandler(createProjectHandler)).Methods("POST")
apirouter.Handle("/projects/{projectref}", authForcedHandler(updateProjectHandler)).Methods("PUT") apirouter.Handle("/projects/{projectref}", authForcedHandler(updateProjectHandler)).Methods("PUT")
apirouter.Handle("/projects/{projectref}", authForcedHandler(deleteProjectHandler)).Methods("DELETE") apirouter.Handle("/projects/{projectref}", authForcedHandler(deleteProjectHandler)).Methods("DELETE")