diff options
author | Valery Piashchynski <[email protected]> | 2020-12-26 13:13:59 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2020-12-26 13:13:59 +0300 |
commit | 1aaf6e6ffb015cd5a21d9d938ad84c18723973c5 (patch) | |
tree | 7221427ba25f8f99a10720778a420703dc2bff92 /pkg/worker/worker.go | |
parent | de4d0b6e66ceda08b0daec18a218c1baa71ebf04 (diff) |
Reorganize eventsv2.0.0-beta4
Diffstat (limited to 'pkg/worker/worker.go')
-rwxr-xr-x | pkg/worker/worker.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/worker/worker.go b/pkg/worker/worker.go index db182a3e..493882a8 100755 --- a/pkg/worker/worker.go +++ b/pkg/worker/worker.go @@ -117,7 +117,7 @@ func InitBaseWorker(cmd *exec.Cmd, options ...Options) (worker.BaseProcess, erro return w, nil } -func AddListeners(listeners ...events.EventListener) Options { +func AddListeners(listeners ...events.Listener) Options { return func(p *Process) { for i := 0; i < len(listeners); i++ { p.addListener(listeners[i]) @@ -136,7 +136,7 @@ func (w *Process) Created() time.Time { } // AddListener registers new worker event listener. -func (w *Process) addListener(listener events.EventListener) { +func (w *Process) addListener(listener events.Listener) { w.events.AddListener(listener) } |