From 907fb38f0a01f1726ff6595964053f939b9c16cb Mon Sep 17 00:00:00 2001 From: geek Date: Thu, 11 May 2017 18:05:39 +0900 Subject: [PATCH] agent observer message modify --- init_method.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init_method.go b/init_method.go index b205478..c199a67 100644 --- a/init_method.go +++ b/init_method.go @@ -26,10 +26,10 @@ func agentStartHandler() { func agentEndHandler() { agentEnd := make(chan interface{}, 0) - observer.Add(messages.AGT_WILL_STOPPED, agentEnd) + observer.Add(messages.AGT_WILL_STOP, agentEnd) go func() { _ = <-agentEnd - observer.Remove(messages.AGT_WILL_STOPPED, agentEnd) + observer.Remove(messages.AGT_WILL_STOP, agentEnd) observer.Remove(messages.TASK_SENSOR_ADD,_configManager.addCh) observer.Remove(messages.TASK_SENSOR_REMOVE,_configManager.removeCh) }()