19889: Fix webdav methods condition.
authorTom Clegg <tom@curii.com>
Thu, 23 Mar 2023 15:14:49 +0000 (11:14 -0400)
committerTom Clegg <tom@curii.com>
Thu, 23 Mar 2023 15:14:49 +0000 (11:14 -0400)
Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tom@curii.com>

lib/controller/router/router.go

index f2d1e1f0a7bcd7284f304832d9b219701fc0760d..72e5ab3108432a25e5d213681eff0e9c29aafab9 100644 (file)
@@ -623,7 +623,7 @@ func (rtr *router) addRoute(endpoint arvados.APIEndpoint, defaultOpts func() int
        if alt, ok := altMethod[endpoint.Method]; ok {
                methods = append(methods, alt)
        }
-       if strings.HasPrefix(endpoint.Path, strings.TrimSuffix(arvados.EndpointContainerLog.Path, "/{path:.*}")) {
+       if strings.HasSuffix(endpoint.Path, ".*}") {
                // webdav methods
                methods = append(methods, "OPTIONS", "PROPFIND")
        }