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

Components: Mimic URLInput request abort on fetch #8049

Merged
merged 3 commits into from
Jul 19, 2018

Conversation

aduth
Copy link
Member

@aduth aduth commented Jul 19, 2018

Fixes #8034

This pull request seeks to resolve an error which occurs when assigning the URL of a Button block. Notably, it replaces Promise#abort (which does not exist) with an equivalent implementation checking for the request reference in an array which is reset both on subsequent requests and unmounting (when previously we were calling abort).

Testing instructions:

Repeat testing instructions from #8034, ensuring there are no errors.

@aduth aduth added the [Feature] UI Components Impacts or related to the UI component system label Jul 19, 2018
@aduth aduth added this to the 3.3 milestone Jul 19, 2018
@aduth aduth requested a review from youknowriad July 19, 2018 13:32
Copy link
Contributor

@youknowriad youknowriad left a comment

Choose a reason for hiding this comment

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

LGTM 👍

onlyScrollIfNeeded: true,
} );

setTimeout( () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Unrelated, we should probably replace this with withSafeTimeout :)

Copy link
Member Author

Choose a reason for hiding this comment

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

We should probably not have setTimeout of any form 😉

@aduth aduth merged commit 348e463 into master Jul 19, 2018
@aduth aduth deleted the fix/8034-url-input-error branch July 19, 2018 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] UI Components Impacts or related to the UI component system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Components: Error when URLInput updates its suggestions
2 participants