Skip to content

Commit

Permalink
fix: don't sent device name if DefaultPII is disabled (#2354)
Browse files Browse the repository at this point in the history
  • Loading branch information
vaind authored Nov 14, 2022
1 parent 38e4f11 commit 642001e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Fixes

- Fix `Gpu.vendorId` should be a String ([#2343](https://github.com/getsentry/sentry-java/pull/2343))
- Don't set device name on Android if `sendDefaultPii` is disabled ([#2354](https://github.com/getsentry/sentry-java/pull/2354))

### Features

Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ We suggest opening an issue to discuss bigger changes before investing on a big

# Requirements

The project currently requires you run JDK 11.
The project currently requires you run JDK 17.

## Android

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ public DefaultAndroidEventProcessor(

ExecutorService executorService = Executors.newSingleThreadExecutor();
// dont ref. to method reference, theres a bug on it
//noinspection Convert2MethodRef
contextData = executorService.submit(() -> loadContextData());

executorService.shutdown();
Expand Down Expand Up @@ -282,7 +283,9 @@ private void setArchitectures(final @NotNull Device device) {
// TODO: missing usable memory

Device device = new Device();
device.setName(getDeviceName());
if (options.isSendDefaultPii()) {
device.setName(getDeviceName());
}
device.setManufacturer(Build.MANUFACTURER);
device.setBrand(Build.BRAND);
device.setFamily(getFamily());
Expand Down

0 comments on commit 642001e

Please sign in to comment.