summaryrefslogtreecommitdiffstats
path: root/app/plugin_deadlock_test.go
diff options
context:
space:
mode:
authorJesse Hallam <jesse.hallam@gmail.com>2018-08-03 13:15:51 -0400
committerGitHub <noreply@github.com>2018-08-03 13:15:51 -0400
commit04749027f62a6c830bdc33b793c24c13b9fb8ba2 (patch)
tree6b26ba82453ba6ccc2dcab0a721d0539ae19a351 /app/plugin_deadlock_test.go
parent1ecb98d9f5a6053a1ee1ce262b6a3306192f6616 (diff)
downloadchat-04749027f62a6c830bdc33b793c24c13b9fb8ba2.tar.gz
chat-04749027f62a6c830bdc33b793c24c13b9fb8ba2.tar.bz2
chat-04749027f62a6c830bdc33b793c24c13b9fb8ba2.zip
MM-11575: change plugin nil semantics (#9212)
* change MessageWillBePosted nil return semantics * change FileWillBeUploaded nil return semantics * use LogDebug to verify plugin inputs vs. the confusing Delete(User|Team)
Diffstat (limited to 'app/plugin_deadlock_test.go')
-rw-r--r--app/plugin_deadlock_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/plugin_deadlock_test.go b/app/plugin_deadlock_test.go
index 381206943..1dcaaa228 100644
--- a/app/plugin_deadlock_test.go
+++ b/app/plugin_deadlock_test.go
@@ -45,7 +45,7 @@ func TestPluginDeadlock(t *testing.T) {
func (p *MyPlugin) MessageWillBePosted(c *plugin.Context, post *model.Post) (*model.Post, string) {
if _, from_plugin := post.Props["from_plugin"]; from_plugin {
- return post, ""
+ return nil, ""
}
p.API.CreatePost(&model.Post{
@@ -57,7 +57,7 @@ func TestPluginDeadlock(t *testing.T) {
},
})
- return post, ""
+ return nil, ""
}
func main() {
@@ -120,7 +120,7 @@ func TestPluginDeadlock(t *testing.T) {
func (p *MyPlugin) MessageWillBePosted(c *plugin.Context, post *model.Post) (*model.Post, string) {
if _, from_plugin := post.Props["from_plugin"]; from_plugin {
- return post, ""
+ return nil, ""
}
p.API.CreatePost(&model.Post{
@@ -132,7 +132,7 @@ func TestPluginDeadlock(t *testing.T) {
},
})
- return post, ""
+ return nil, ""
}
func main() {