Skip to content
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

[DOC] lost response.timestamp when running an example #1695

Closed
cainiaoDJ opened this issue Dec 29, 2020 · 0 comments
Closed

[DOC] lost response.timestamp when running an example #1695

cainiaoDJ opened this issue Dec 29, 2020 · 0 comments

Comments

@cainiaoDJ
Copy link
Contributor

Describe the bug
read _examples\mvc\error-handler-preflight\main.go code, there is response.Timestamp in response object, but it not appear in the response when I call "http://lcoalhost:8080/1"
I think the field of timestamp should appear in returns when response.ID > 0, otherwise this is a meaningless field。

To Reproduce

cd _examples/mvc/error-handler-preflight
go run main.go
curl --location --request GET 'http://127.0.0.1:8080/1'

Expected behavior

{
    "id": 1,
    "data": {
        "id": 1
    },
    "timestamp": 1609227854
}

Desktop (please complete the following information):

  • OS: windows10

iris.Version

  • master
@kataras kataras changed the title [BUG] lost response.timestamp when running an example [DOC] lost response.timestamp when running an example Jan 9, 2021
@kataras kataras closed this as completed Jan 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants