Skip to content
Snippets Groups Projects
Commit d226d63d authored by 382673304@qq.com's avatar 382673304@qq.com
Browse files

fix: fix destory unregister bug

parent da4d82fb
No related branches found
No related tags found
No related merge requests found
......@@ -187,5 +187,10 @@ func (r *consulRegistry) IsAvailable() bool {
// Destroy consul registry center
func (r *consulRegistry) Destroy() {
if r.URL != nil{
if err := r.UnRegister(*r.URL); err != nil{
logger.Errorf("consul registry unregister with err: %s", err.Error())
}
}
close(r.done)
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment