switch to POST method in rest endpoint and do not replace http:// by default

This commit is contained in:
David Remer 2020-07-06 13:56:33 +03:00
parent ff0e7b2af6
commit 524809d6f6

View file

@ -24,7 +24,7 @@ class IncomingWebhookEndpoint
self::ROUTE,
[
'methods' => [
'GET',
'POST',
],
'callback' => [
$this,
@ -44,7 +44,7 @@ class IncomingWebhookEndpoint
}
public function url() : string {
return str_replace('http://', 'https://', rest_url(self::NAMESPACE . '/' . self::ROUTE ));
return rest_url(self::NAMESPACE . '/' . self::ROUTE);
}
public function handledEventTypes() : array {