Log loaded plugins
If a plugin was built for a different gotify version, then plugin.Open may throw an unrecoverable error. This log statement should help debugging which plugin is causing the error. See #510
This commit is contained in:
parent
c4e63863f7
commit
0250a48c2c
|
|
@ -227,6 +227,8 @@ func (m *Manager) loadPlugins(directory string) error {
|
||||||
}
|
}
|
||||||
for _, f := range pluginFiles {
|
for _, f := range pluginFiles {
|
||||||
pluginPath := filepath.Join(directory, "./", f.Name())
|
pluginPath := filepath.Join(directory, "./", f.Name())
|
||||||
|
|
||||||
|
fmt.Println("Loading plugin", pluginPath)
|
||||||
pRaw, err := plugin.Open(pluginPath)
|
pRaw, err := plugin.Open(pluginPath)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return pluginFileLoadError{f.Name(), err}
|
return pluginFileLoadError{f.Name(), err}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue