Skip to content

Commit eed72ba

Browse files
committed
docs: update plugin template
1 parent 6d3a553 commit eed72ba

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

docs/plugin/templateplugin.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,14 @@ func (d *TemplatePlugin) SetURL(url string) {
6363

6464
// Connect to service if needed
6565
func (d *TemplatePlugin) Connect() error {
66+
if d.logger == nil {
67+
d.logger = tob.Logger
68+
}
69+
70+
if d.stopChan == nil {
71+
d.stopChan = make(chan bool, 1)
72+
}
73+
6674
if d.verbose {
6775
d.logger.Println("connect dummy")
6876
}

0 commit comments

Comments
 (0)