diff options
author | cpanato <ctadeu@gmail.com> | 2018-07-12 19:50:16 +0200 |
---|---|---|
committer | cpanato <ctadeu@gmail.com> | 2018-07-12 19:50:16 +0200 |
commit | adc56ae78df2a84c14c5e2921ec9cb14817a2474 (patch) | |
tree | a66d4646ecc3baef4d365f7148fe3921ab267e15 /api4/post_test.go | |
parent | 8cad7070acc537d070edd1029fe0c6ce422ab0ed (diff) | |
parent | 2e861c4df4063f325df40861ee045c0136d34f1e (diff) | |
download | chat-adc56ae78df2a84c14c5e2921ec9cb14817a2474.tar.gz chat-adc56ae78df2a84c14c5e2921ec9cb14817a2474.tar.bz2 chat-adc56ae78df2a84c14c5e2921ec9cb14817a2474.zip |
Merge remote-tracking branch 'upstream/release-5.1' into release-5.1-daily-merge-20180712
Diffstat (limited to 'api4/post_test.go')
-rw-r--r-- | api4/post_test.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/api4/post_test.go b/api4/post_test.go index 63d71b5bd..720fdc410 100644 --- a/api4/post_test.go +++ b/api4/post_test.go @@ -170,6 +170,15 @@ func testCreatePostWithOutgoingHook( team := th.BasicTeam channel := th.BasicChannel + enableOutgoingWebhooks := th.App.Config().ServiceSettings.EnableOutgoingWebhooks + allowedUntrustedInternalConnections := th.App.Config().ServiceSettings.AllowedUntrustedInternalConnections + defer func() { + th.App.UpdateConfig(func(cfg *model.Config) { cfg.ServiceSettings.EnableOutgoingWebhooks = enableOutgoingWebhooks }) + th.App.UpdateConfig(func(cfg *model.Config) { + cfg.ServiceSettings.AllowedUntrustedInternalConnections = allowedUntrustedInternalConnections + }) + }() + th.App.UpdateConfig(func(cfg *model.Config) { cfg.ServiceSettings.EnableOutgoingWebhooks = true }) th.App.UpdateConfig(func(cfg *model.Config) { *cfg.ServiceSettings.AllowedUntrustedInternalConnections = "localhost 127.0.0.1" |