Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix(net/gclient): fix content-type 'application/json;charset=utf-8' …#4369

Merged
hailaz merged 6 commits intogogf:masterfrom
wanghaolong613:fix/content-type
Oct 15, 2025
Merged

fix(net/gclient): fix content-type 'application/json;charset=utf-8' …#4369
hailaz merged 6 commits intogogf:masterfrom
wanghaolong613:fix/content-type

Conversation

@wanghaolong613
Copy link
Contributor

fix(net/gclient): fix content-type 'application/json;charset=utf-8' can not match application/json

@houseme houseme requested review from Copilot and hailaz August 28, 2025 11:13
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes a content-type matching issue where content types with charset parameters (e.g., 'application/json;charset=utf-8') were not properly matching the expected 'application/json' type.

Key Changes

  • Imported the mime package to parse media types
  • Modified content-type handling to extract the media type portion before charset parameters

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@hailaz hailaz merged commit 2744fe2 into gogf:master Oct 15, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants