Skip to content
This repository was archived by the owner on Jul 9, 2026. It is now read-only.

Update userAgent override to be string instead of array - #3880

Merged
guarani merged 3 commits into
developfrom
fix/user-agent-string
Aug 26, 2021
Merged

guarani merged 3 commits into
developfrom
fix/user-agent-string

Conversation

@guarani

@guarani guarani commented Aug 26, 2021 •

Copy link
Copy Markdown
Contributor

This fixes issues that arose while working on the Jetpack Tiled Gallery (see #3875) where we ran into an error because the JSDOM user agent is incorrectly overridden to be an empty array, instead of an empty string. The debug third-party libraries used by Jetpack queried the user agent crashed when it encountered the wrong type (expected string, got array).

Related:

To test, ensure CI checks pass.

PR submission checklist:

  • I have considered adding unit tests where possible.
  • I have considered if this change warrants user-facing release notes more info and have added them to RELEASE-NOTES.txt if necessary.

@mchowning mchowning left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@peril-wordpress-mobile

peril-wordpress-mobile Bot commented Aug 26, 2021 •

Copy link
Copy Markdown

Wanna run full suite of Android and iOS UI tests? Click here and 'Approve' CI job!

@guarani
guarani enabled auto-merge August 26, 2021 22:13
@guarani
guarani merged commit 520ab11 into develop Aug 26, 2021
@guarani
guarani deleted the fix/user-agent-string branch August 26, 2021 22:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

[Type] Bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants