Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
* dev:
  Bump version 7.3.2.
  fix(android): Adding Java 8 compile options for Android instrumented tests
  Fix: Foreground notifications missing small icon
  • Loading branch information
Dallas62 committed Jun 19, 2021
2 parents 4aaaf48 + c1d6ee5 commit a15978c
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html

### Fixed

## [7.3.2] 2021-05-12

### Fixed

- (Android) Fix: Foreground notifications missing small icon. [#1927](https://github.com/zo0r/react-native-push-notification/pull/1927)

## [7.3.1] 2021-05-12

### Fixed
Expand Down
5 changes: 5 additions & 0 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ android {
compileSdkVersion safeExtGet('compileSdkVersion', 28)
buildToolsVersion safeExtGet('buildToolsVersion', '28.0.3')

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

defaultConfig {
minSdkVersion safeExtGet('minSdkVersion', 16)
targetSdkVersion safeExtGet('targetSdkVersion', 28)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ public void handleReceivedMessage(RemoteMessage message) {
bundle.putString("color", remoteNotification.getColor());
bundle.putString("tag", remoteNotification.getTag());

if(remoteNotification.getIcon() != null) {
bundle.putString("smallIcon", remoteNotification.getIcon());
} else {
bundle.putString("smallIcon", "ic_notification");
}

if(remoteNotification.getChannelId() != null) {
bundle.putString("channelId", remoteNotification.getChannelId());
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-native-push-notification",
"version": "7.3.1",
"version": "7.3.2",
"description": "React Native Local and Remote Notifications",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit a15978c

Please sign in to comment.