Skip to content
This repository has been archived by the owner on Jul 18, 2018. It is now read-only.

Commit

Permalink
Make PerformanceEntry::toEntryTypeEnum case sensitive.
Browse files Browse the repository at this point in the history
The performance timing spec has been clarified[1] to make getEntriesByType
case sensitive. This CL updates Blink to this new requirement.

[1] w3c/performance-timeline#57

BUG=651507

Review-Url: https://codereview.chromium.org/2390733003
Cr-Commit-Position: refs/heads/master@{#422650}
  • Loading branch information
dj2 authored and Commit bot committed Oct 4, 2016
1 parent 8d53345 commit 9c0ff24
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions third_party/WebKit/Source/core/timing/PerformanceEntry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,17 +65,17 @@ double PerformanceEntry::duration() const {

PerformanceEntry::EntryType PerformanceEntry::toEntryTypeEnum(
const String& entryType) {
if (equalIgnoringCase(entryType, "composite"))
if (entryType == "composite")
return Composite;
if (equalIgnoringCase(entryType, "longtask"))
if (entryType == "longtask")
return LongTask;
if (equalIgnoringCase(entryType, "mark"))
if (entryType == "mark")
return Mark;
if (equalIgnoringCase(entryType, "measure"))
if (entryType == "measure")
return Measure;
if (equalIgnoringCase(entryType, "render"))
if (entryType == "render")
return Render;
if (equalIgnoringCase(entryType, "resource"))
if (entryType == "resource")
return Resource;
return Invalid;
}
Expand Down

0 comments on commit 9c0ff24

Please sign in to comment.