Fixed #15946 - added comtent type to webhook test
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
57f80290a1
commit
221ffb446c
1 changed files with 1 additions and 1 deletions
|
@ -159,7 +159,7 @@ class SlackSettingsForm extends Component
|
||||||
]);
|
]);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$test = $webhook->post($this->webhook_endpoint, ['body' => $payload]);
|
$test = $webhook->post($this->webhook_endpoint, ['body' => $payload, ['headers' => ['Content-Type' => 'application/json']]]);
|
||||||
|
|
||||||
if(($test->getStatusCode() == 302)||($test->getStatusCode() == 301)){
|
if(($test->getStatusCode() == 302)||($test->getStatusCode() == 301)){
|
||||||
return session()->flash('error' , trans('admin/settings/message.webhook.error_redirect', ['endpoint' => $this->webhook_endpoint]));
|
return session()->flash('error' , trans('admin/settings/message.webhook.error_redirect', ['endpoint' => $this->webhook_endpoint]));
|
||||||
|
|
Loading…
Add table
Reference in a new issue