Skip to content

add ok prop for response #1

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
Closed

add ok prop for response #1

wants to merge 1 commit into from

Conversation

bobenut
Copy link

@bobenut bobenut commented Mar 14, 2018

Hi
react-fetch-mock is very useful for me. thank u.
Sometimes it is necessary to check if response is ok using Response.ok.
According to fetch api specification. I added ‘ok’ prop into response object.
fetch specification:
https://developer.mozilla.org/en-US/docs/Web/API/Response/ok

@bobenut
Copy link
Author

bobenut commented Mar 14, 2018

but i haven't compile into dist.
what do you think about it/

@@ -135,6 +135,7 @@ class FetchMock {
obj = {
status: 200,
data: obj,
ok: true
Copy link
Owner

Choose a reason for hiding this comment

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

It is unnecessary

Copy link
Author

Choose a reason for hiding this comment

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

got it

@WhatAKitty
Copy link
Owner

WhatAKitty commented Mar 14, 2018

@bobenut I'll do it after I merged this pr.

@bobenut
Copy link
Author

bobenut commented Mar 15, 2018

ok thx

@WhatAKitty
Copy link
Owner

@bobenut
207cd6e

@WhatAKitty WhatAKitty closed this Mar 22, 2018
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.

2 participants