Modifying webhook request options requires overwriting entire method

Changing the options for sending a webhook request currently requires overwriting whole method run

Could the code to set the options be moved to its own method, eg. smth. like

PHP:

Код:
protected function getRequestOptions(Webhook $webhook): array
{
    $options['headers'] = [
        'XF-Content-Type' => $this->data['content_type'],
        'XF-Webhook-Event' => $this->data['event'],
        'XF-Webhook-Id' => $webhook->webhook_id,
    ];
   
    [...]

    return $options;
}
?

This...

Read more

Читать далее...
 
Активность
Пока что здесь никого нет

Похожие темы

Назад
Верх Низ