diff options
author | Chris <ccbrown112@gmail.com> | 2017-12-05 08:19:32 -0600 |
---|---|---|
committer | Joram Wilander <jwawilander@gmail.com> | 2017-12-05 09:19:32 -0500 |
commit | 3c7b40063dbba777d27efd2fa4c7093d5507dca6 (patch) | |
tree | 81b77acde7ae6eb2909e2d99782f51f4989dd5cf /plugin/example_hello_user_test.go | |
parent | 7a1f81cd52c4b58a058ae11e361a80ee3b24d141 (diff) | |
download | chat-3c7b40063dbba777d27efd2fa4c7093d5507dca6.tar.gz chat-3c7b40063dbba777d27efd2fa4c7093d5507dca6.tar.bz2 chat-3c7b40063dbba777d27efd2fa4c7093d5507dca6.zip |
call OnActivate after plugin crash, update example (#7940)
Diffstat (limited to 'plugin/example_hello_user_test.go')
-rw-r--r-- | plugin/example_hello_user_test.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugin/example_hello_user_test.go b/plugin/example_hello_user_test.go index 4aefbc5f5..989cca0f2 100644 --- a/plugin/example_hello_user_test.go +++ b/plugin/example_hello_user_test.go @@ -12,9 +12,10 @@ type HelloUserPlugin struct { api plugin.API } -func (p *HelloUserPlugin) OnActivate(api plugin.API) { +func (p *HelloUserPlugin) OnActivate(api plugin.API) error { // Just save api for later when we need to look up users. p.api = api + return nil } func (p *HelloUserPlugin) ServeHTTP(w http.ResponseWriter, r *http.Request) { |