remove trailing / on leases API endpoint (#11959)

This commit is contained in:
swayne275 2021-06-30 13:02:26 -06:00 committed by GitHub
parent f882c31856
commit fd517e6114
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 1 additions and 3 deletions

View File

@ -107,7 +107,6 @@ func NewSystemBackend(core *Core, logger log.Logger) *SystemBackend {
"leases/lookup/*", "leases/lookup/*",
"storage/raft/snapshot-auto/config/*", "storage/raft/snapshot-auto/config/*",
"leases", "leases",
"leases/",
}, },
Unauthenticated: []string{ Unauthenticated: []string{

View File

@ -1253,7 +1253,7 @@ func (b *SystemBackend) leasePaths() []*framework.Path {
}, },
{ {
Pattern: "leases(/)?$", Pattern: "leases$",
Fields: map[string]*framework.FieldSchema{ Fields: map[string]*framework.FieldSchema{
"type": { "type": {
Type: framework.TypeString, Type: framework.TypeString,

View File

@ -58,7 +58,6 @@ func TestSystemBackend_RootPaths(t *testing.T) {
"leases/lookup/*", "leases/lookup/*",
"storage/raft/snapshot-auto/config/*", "storage/raft/snapshot-auto/config/*",
"leases", "leases",
"leases/",
} }
b := testSystemBackend(t) b := testSystemBackend(t)