Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

fix(util): check for definition of window.performance.now before using in mdUtil #9664

Merged
merged 1 commit into from
Sep 26, 2016

Conversation

justinappler
Copy link
Contributor

The previous behavior assumes the existence of the now() function in browsers that provide the
window.performance API. This change verifies it is available and if not, uses existing fallbacks.

According to the Mozilla Developer Network reference page, the following browsers have the window.performance API, but not support for now():

  • Chrome 6-23
  • Firefox 7-14
  • IE 9

…g in mdUtil

The previous behavior assumes the existence of the now() function in browsers that provide the 
window.performance API. This change verifies it is available and if not, uses existing fallbacks.
Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

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

LGTM @ThomasBurleson. We actually recently dealt with something similar in #9254.

@crisbeto crisbeto added the needs: review This PR is waiting on review from the team label Sep 22, 2016
@ThomasBurleson ThomasBurleson added needs: presubmit and removed needs: review This PR is waiting on review from the team labels Sep 26, 2016
@ThomasBurleson ThomasBurleson added this to the 1.1.2 milestone Sep 26, 2016
@hansl hansl merged commit 1b9245a into angular:master Sep 26, 2016
@justinappler justinappler deleted the patch-1 branch September 26, 2016 18:18
Frank3K pushed a commit to Frank3K/material that referenced this pull request Oct 8, 2016
…g in mdUtil (angular#9664)

The previous behavior assumes the existence of the now() function in browsers that provide the 
window.performance API. This change verifies it is available and if not, uses existing fallbacks.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants