weldr: Return dependencies for /api/v1/modules/info
Previously the API handler was only checking for a match to /api/v0/modules/info, this adds a test for v1 and a test to make sure it works the same.
This commit is contained in:
parent
dc31fb3f21
commit
f9bfd17928
2 changed files with 3 additions and 1 deletions
|
|
@ -933,7 +933,8 @@ func (api *API) modulesInfoHandler(writer http.ResponseWriter, request *http.Req
|
|||
}
|
||||
|
||||
// handle both projects/info and modules/info, the latter includes dependencies
|
||||
modulesRequested := strings.HasPrefix(request.URL.Path, "/api/v0/modules")
|
||||
modulesRequested := strings.HasPrefix(request.URL.Path, "/api/v0/modules") ||
|
||||
strings.HasPrefix(request.URL.Path, "/api/v1/modules")
|
||||
|
||||
var errorId, unknownErrorId string
|
||||
if modulesRequested {
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue