Skip to content

Remove includes in favor or indexOf for IE support #2683

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

Merged
merged 1 commit into from
Jun 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/apm/src/integrations/tracing.ts
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ export class Tracing implements Integration {
resource.startTimestamp = timeOrigin + startTime;
resource.endTimestamp = resource.startTimestamp + duration;
// We remember the entry script end time to calculate the difference to the first init mark
if (entryScriptStartEndTime === undefined && (entryScriptSrc || '').includes(resourceName)) {
if (entryScriptStartEndTime === undefined && (entryScriptSrc || '').indexOf(resourceName) > -1) {
entryScriptStartEndTime = resource.endTimestamp;
}
}
Expand Down
2 changes: 1 addition & 1 deletion packages/integrations/src/vue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ export class Vue implements Integration {
const childHandler = (hook: Hook, operation: Operation) => {
// Skip components that we don't want to track to minimize the noise and give a more granular control to the user
const shouldTrack = Array.isArray(this._options.tracingOptions.trackComponents)
? this._options.tracingOptions.trackComponents.includes(name)
? this._options.tracingOptions.trackComponents.indexOf(name) > -1
: this._options.tracingOptions.trackComponents;

if (!this._rootSpan || !shouldTrack) {
Expand Down