mirror of
https://github.com/alvierahman90/gohookr.git
synced 2024-12-22 08:42:00 +00:00
fix program arguments not being passed to commands
This commit is contained in:
parent
f13dbe3250
commit
7c778d4e48
@ -15,8 +15,8 @@ type Command struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (c Command) Execute(payload string, header http.Header) ([]byte, error) {
|
func (c Command) Execute(payload string, header http.Header) ([]byte, error) {
|
||||||
arguments := make([]string, 0)
|
arguments := make([]string, len(c.Arguments))
|
||||||
copy(c.Arguments, arguments)
|
copy(arguments, c.Arguments)
|
||||||
|
|
||||||
if c.AppendPayload {
|
if c.AppendPayload {
|
||||||
arguments = append(arguments, payload)
|
arguments = append(arguments, payload)
|
||||||
|
Loading…
Reference in New Issue
Block a user