Skip to content

Commit f440cfd

Browse files
ThavarshanCopilot
andcommitted
Update src/Fetch/Concerns/ConfiguresRequests.php
Co-authored-by: Copilot <[email protected]>
1 parent af52d14 commit f440cfd

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/Fetch/Concerns/ConfiguresRequests.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -208,9 +208,7 @@ public function withBody(array|string $body, string|ContentType $contentType = C
208208
// For string bodies, use body option
209209
$this->options['body'] = $body;
210210
// Remove body-related options to prevent conflicts
211-
unset($this->options['json']);
212-
unset($this->options['form_params']);
213-
unset($this->options['multipart']);
211+
$this->unsetConflictingOptions(['json', 'form_params', 'multipart']);
214212
if (! $this->hasHeader('Content-Type')) {
215213
$this->withHeader('Content-Type', $contentTypeValue);
216214
}

0 commit comments

Comments
 (0)