get apiPlugins working again.

This commit is contained in:
Anthony Woods
2016-01-20 06:13:45 +08:00
parent 7a26d309b1
commit c4a0ec844c
2 changed files with 40 additions and 0 deletions
+9
View File
@@ -73,3 +73,12 @@ func NewEnabledPlugins() EnabledPlugins {
Apps: make([]*AppPlugin, 0),
}
}
func (app *ApiPlugin) Load(decoder *json.Decoder, pluginDir string) error {
if err := decoder.Decode(&app); err != nil {
return err
}
ApiPlugins[app.Id] = app
return nil
}