mirror of
https://github.com/coder/coder.git
synced 2025-07-03 16:13:58 +00:00
chore: don't require an organization to read starter templates (#14190)
This commit is contained in:
committed by
GitHub
parent
fab196043e
commit
ff785588fe
@ -871,7 +871,7 @@ func New(options *Options) *API {
|
||||
r.Route("/templates", func(r chi.Router) {
|
||||
r.Post("/", api.postTemplateByOrganization)
|
||||
r.Get("/", api.templatesByOrganization())
|
||||
r.Get("/examples", api.templateExamples)
|
||||
r.Get("/examples", api.templateExamplesByOrganization)
|
||||
r.Route("/{templatename}", func(r chi.Router) {
|
||||
r.Get("/", api.templateByOrganizationAndName)
|
||||
r.Route("/versions/{templateversionname}", func(r chi.Router) {
|
||||
@ -915,6 +915,7 @@ func New(options *Options) *API {
|
||||
apiKeyMiddleware,
|
||||
)
|
||||
r.Get("/", api.fetchTemplates(nil))
|
||||
r.Get("/examples", api.templateExamples)
|
||||
r.Route("/{template}", func(r chi.Router) {
|
||||
r.Use(
|
||||
httpmw.ExtractTemplateParam(options.Database),
|
||||
|
Reference in New Issue
Block a user