Fix initialization to use apid events instead of a new plugin callback
diff --git a/init.go b/init.go index 6e0bcba..844c98e 100644 --- a/init.go +++ b/init.go
@@ -28,10 +28,9 @@ func init() { apid.RegisterPlugin(initPlugin) - apid.RegisterPostPlugin(postinitPlugin) } -func postinitPlugin(services apid.Services) error { +func postInitPlugins() { log.Debug("start post plugin init") /* call to Download Snapshot info */ @@ -43,8 +42,6 @@ events.Listen(ApigeeSyncEventSelector, &handler{}) log.Debug("Done post plugin init") - return nil - } func initPlugin(services apid.Services) error { @@ -55,6 +52,8 @@ data = services.Data() events = services.Events() + events.Listen(apid.PluginsInitializedEvent, postInitPlugins) + config.SetDefault(configPollInterval, 120) db, err := data.DB()