Skip to content

Commit

Permalink
Update style to fit inside module
Browse files Browse the repository at this point in the history
  • Loading branch information
acmiyaguchi committed Feb 8, 2021
1 parent b8172c4 commit 9cc909a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ public static void scrub(Map<String, String> attributes, ObjectNode json)
final String appVersion = attributes.get(Attribute.APP_VERSION);
final String appUpdateChannel = attributes.get(Attribute.APP_UPDATE_CHANNEL);
final String appBuildId = attributes.get(Attribute.APP_BUILD_ID);
final String userAgent = attributes.get(Attribute.USER_AGENT);

// Check for toxic data that should be dropped without sending to error output.
if (ParseUri.TELEMETRY.equals(namespace) && "crash".equals(docType)
Expand Down Expand Up @@ -132,8 +133,7 @@ public static void scrub(Map<String, String> attributes, ObjectNode json)

// Glean enforces a particular user-agent string that a rogue fuzzer is not abiding by
// https://searchfox.org/mozilla-central/source/third_party/rust/glean-core/src/upload/request.rs#35,72-75
if (attributes.get(Attribute.DOCUMENT_NAMESPACE).equals("firefox-desktop")
&& !attributes.get(Attribute.USER_AGENT).startsWith("Glean")) {
if ("firefox-desktop".equals(namespace) && !userAgent.startsWith("Glean")) {
throw new UnwantedDataException("1684980");
}

Expand Down

0 comments on commit 9cc909a

Please sign in to comment.