Skip to content

fix(net/ghttp): 修复请求成功时,返回数据的ghttp默认中间件message字段为空的问题 #4124

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

xyle
Copy link

@xyle xyle commented Jan 18, 2025

No description provided.

修复请求成功时,ghttp默认返回数据中间件message字段为空的问题
@gqcn
Copy link
Member

gqcn commented Jan 22, 2025

@xyle 你好,请描述下这样修改的必要性呢?或者阐述下对应的业务场景?

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@xyle Hello, please describe the necessity of such modification? Or explain the corresponding business scenario?

@xyle
Copy link
Author

xyle commented Feb 15, 2025 via email

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Although message fields are not strictly required in API design, they are often considered a useful feature because they provide additional information, help developers understand what the response means, and enhance API usability. Therefore, in most cases it is recommended to include a message field, especially if the API may be used by developers of different backgrounds.
When the front-end calls the API interface, some interfaces will generally display the field information to the user regardless of whether the request is successful or failed, otherwise the prompt information needs to be processed manually. Adding successful messages can simplify this processing flow.

Personal suggestions, please consider whether it is reasonable, thank you!

Tian Butian
@.***

   


From: "gogf/gf" @.>;
Send time: January 22, 2025 (Wednesday) 10:21 am
@.
>;
@.***@.>;
Topic: Re: [gogf/gf] fix(net/ghttp): Fixed the issue that the default middleware message field that returns data is empty when the request is successful (PR #4124)

@xyle Hello, please describe the necessity of such modification? Or explain the corresponding business scenarios?


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: @.***>

@gqcn gqcn closed this Feb 20, 2025
@gqcn gqcn added the rejected The proposal or PR is not accepted, which might be conflicted with our design or plan. label Feb 20, 2025
@gogf gogf deleted a comment from Issues-translate-bot Feb 20, 2025
@gqcn
Copy link
Member

gqcn commented Feb 20, 2025

@xyle 你好,这个修复会更合适一些 #4162

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


@xyle Hello, this fix will be more suitable #4162

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rejected The proposal or PR is not accepted, which might be conflicted with our design or plan.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants