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

fix(popover): clear popover delayCheckHover timeout #622

Merged
merged 4 commits into from
Jul 29, 2020

Conversation

robstax
Copy link
Collaborator

@robstax robstax commented Jun 25, 2020

Description

delayCheckHover creates a timeout that we aren't keeping track of, which is a memory leak. this PR fixes that. everything else is formatting noise.

Motivation and Context

Memory leak and address a warning from React when we setState on an unmounted component.

How Has This Been Tested?

it's difficult to consistently repro the issue, but logically this fixes it.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

if (this.props.closeOnFocusLeavesContent) { // if closeOnFocusLeavesContent = true
if (e.shiftKey) { // SHIFT + TAB
if (this.props.closeOnFocusLeavesContent) {
// if closeOnFocusLeavesContent = true
Copy link
Collaborator

Choose a reason for hiding this comment

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

don't think we need this comment. seems to repeat the code exactly :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

i didn't write the comment. formatting the file moved it to the next line :P

@bfbiggs bfbiggs merged commit 7811cfd into momentum-design:master Jul 29, 2020
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.

4 participants