From a8519a8ebd3fd481bd04ee391bb7ea4e8bf60050 Mon Sep 17 00:00:00 2001 From: Vishal Nayak Date: Mon, 25 Jan 2021 09:35:19 -0500 Subject: [PATCH] =?UTF-8?q?Move=20the=20declaration=20to=20a=20OSS=20build?= =?UTF-8?q?=20tag=20file=20to=20not=20have=20it=20collide=20w=E2=80=A6=20(?= =?UTF-8?q?#10750)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Move the declaration to a OSS build tag file to not have it collide with ent declarations * Add comment * Remove comment to trigger ci --- vault/logical_system.go | 6 ------ vault/logical_system_util.go | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 6 deletions(-) create mode 100644 vault/logical_system_util.go diff --git a/vault/logical_system.go b/vault/logical_system.go index 073ae82b26..698a5c0f79 100644 --- a/vault/logical_system.go +++ b/vault/logical_system.go @@ -3835,12 +3835,6 @@ func (b *SystemBackend) handleLeaderStatus(ctx context.Context, req *logical.Req return httpResp, nil } -func (b *SystemBackend) verifyDROperationToken(f framework.OperationFunc, lock bool) framework.OperationFunc { - return func(ctx context.Context, req *logical.Request, d *framework.FieldData) (*logical.Response, error) { - return f(ctx, req, d) - } -} - func sanitizePath(path string) string { if !strings.HasSuffix(path, "/") { path += "/" diff --git a/vault/logical_system_util.go b/vault/logical_system_util.go new file mode 100644 index 0000000000..d529b39291 --- /dev/null +++ b/vault/logical_system_util.go @@ -0,0 +1,16 @@ +// +build !enterprise + +package vault + +import ( + "context" + + "github.com/hashicorp/vault/sdk/framework" + "github.com/hashicorp/vault/sdk/logical" +) + +func (b *SystemBackend) verifyDROperationToken(f framework.OperationFunc, lock bool) framework.OperationFunc { + return func(ctx context.Context, req *logical.Request, d *framework.FieldData) (*logical.Response, error) { + return f(ctx, req, d) + } +}