diff options
author | Igor Drozdov <idrozdov@gitlab.com> | 2020-04-07 07:00:04 +0300 |
---|---|---|
committer | Ash McKenzie <amckenzie@gitlab.com> | 2020-04-14 23:38:52 +1000 |
commit | 40b3ddc142b906a79f22c726a0a61dd113c39485 (patch) | |
tree | e0b6d0a37d049dbd01e164a95dc0f8728d51d7e2 /internal/command/receivepack/receivepack.go | |
parent | 74bef786d44b270167c7f9dbb029d197fe32ac4f (diff) | |
download | gitlab-shell-40b3ddc142b906a79f22c726a0a61dd113c39485.tar.gz |
Extract customaction into a separate moduleid-extract-custom-action-in-separate-module
We'll reuse this module for uploadpack in the future
Diffstat (limited to 'internal/command/receivepack/receivepack.go')
-rw-r--r-- | internal/command/receivepack/receivepack.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/internal/command/receivepack/receivepack.go b/internal/command/receivepack/receivepack.go index aaaf7b0..3af3941 100644 --- a/internal/command/receivepack/receivepack.go +++ b/internal/command/receivepack/receivepack.go @@ -4,6 +4,7 @@ import ( "gitlab.com/gitlab-org/gitlab-shell/internal/command/commandargs" "gitlab.com/gitlab-org/gitlab-shell/internal/command/readwriter" "gitlab.com/gitlab-org/gitlab-shell/internal/command/shared/accessverifier" + "gitlab.com/gitlab-org/gitlab-shell/internal/command/shared/customaction" "gitlab.com/gitlab-org/gitlab-shell/internal/command/shared/disallowedcommand" "gitlab.com/gitlab-org/gitlab-shell/internal/config" ) @@ -27,7 +28,8 @@ func (c *Command) Execute() error { } if response.IsCustomAction() { - return c.processCustomAction(response) + customAction := customaction.Command{c.Config, c.ReadWriter} + return customAction.Execute(response) } return c.performGitalyCall(response) |