mirror of
https://github.com/fsouza/fake-gcs-server.git
synced 2026-04-26 14:15:49 +03:00
[PR #2129] [MERGED] fakestorage: handle X-HTTP-Method-Override header in updateObject #2123
Labels
No labels
bug
compatibility-issue
docker
documentation
enhancement
help wanted
needs information
pull-request
question
stale
unfortunate
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/fake-gcs-server#2123
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/fsouza/fake-gcs-server/pull/2129
Author: @fsouza
Created: 1/31/2026
Status: ✅ Merged
Merged: 1/31/2026
Merged by: @fsouza
Base:
main← Head:fix-X-HTTP-Method-Override📝 Commits (1)
c5740dafakestorage: handle X-HTTP-Method-Override header inupdateObject📊 Changes
3 files changed (+41 additions, -1 deletions)
View changed files
📝
fakestorage/object.go(+4 -0)📝
fakestorage/object_test.go(+37 -0)📝
fakestorage/server.go(+0 -1)📄 Description
The route with Headers("X-HTTP-Method-Override", "PATCH") wasn't matching requests, causing POST requests with the override header to be handled by
updateObjectinstead ofpatchObject. This resulted in metadata being replaced instead of merged.Instead of relying on the route matcher, check the header directly in
updateObjectand delegate topatchObjectwhen present.Fixes #2036.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.