Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 6ae13cf

Browse filesBrowse files
bug #64458 [Webhook] Fix Content-Type key in createRequest method (MarijnDoeve)
This PR was merged into the 6.4 branch. Discussion ---------- [Webhook] Fix Content-Type key in createRequest method | Q | A | ------------- | --- | Branch? | 6.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | | License | MIT The default behaviour of the abstract test sets the content-type wrong. It will default to a `application/x-www-form-urlencoded` when not set in full caps. <!-- 🛠️ Replace this text with a concise explanation of your change: - What it does and why it's needed - A simple example of how it works (include PHP, YAML, etc.) - If it modifies existing behavior, include a before/after comparison Contributor guidelines: - ✅ Add tests and ensure they pass - 🐞 Bug fixes must target the **lowest maintained** branch where they apply https://symfony.com/releases#maintained-symfony-branches - ✨ New features and deprecations must target the **feature** branch and must add an entry to the changelog file of the patched component: https://symfony.com/doc/current/contributing/code/conventions.html#writing-a-changelog-entry - 🔒 Do not break backward compatibility: https://symfony.com/bc --> Commits ------- d3aacea Fix Content-Type key in createRequest method
2 parents 3d7304b + d3aacea commit 6ae13cf
Copy full SHA for 6ae13cf

1 file changed

+1-1Lines changed: 1 addition & 1 deletion

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/Symfony/Component/Webhook/Test/AbstractRequestParserTestCase.php‎

Copy file name to clipboardExpand all lines: src/Symfony/Component/Webhook/Test/AbstractRequestParserTestCase.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ protected function getSecret(): string
5858
protected function createRequest(string $payload): Request
5959
{
6060
return Request::create('/', 'POST', [], [], [], [
61-
'Content-Type' => 'application/json',
61+
'CONTENT_TYPE' => 'application/json',
6262
], $payload);
6363
}
6464

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.