Skip to content

Commit 58982f3

Browse files
committed
- altered approach to address circular reporting
1 parent 43eb7a5 commit 58982f3

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ repositories {
2222
}
2323
2424
dependencies {
25-
implementation 'com.github.sofwerx:swe-android:1.0.2'
25+
implementation 'com.github.sofwerx:swe-android:1.0.3'
2626
}
2727
```
2828

@@ -39,7 +39,7 @@ dependencies {
3939
<dependency>
4040
<groupId>com.github.sofwerx</groupId>
4141
<artifactId>swe-android</artifactId>
42-
<version>1.0.2</version>
42+
<version>1.0.3</version>
4343
</dependency>
4444
```
4545

SweLib/src/main/java/org/sofwerx/ogc/sos/SosIpcTransceiver.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,11 @@ public void onReceive(Context context, Intent intent) {
6161
String action = intent.getAction();
6262
if (ACTION_SOS.equalsIgnoreCase(action)) {
6363
String origin = intent.getStringExtra(EXTRA_ORIGIN);
64-
if (!BuildConfig.APPLICATION_ID.equalsIgnoreCase(origin))
64+
if (!context.getPackageName().equalsIgnoreCase(origin))
6565
onMessageReceived(context, origin, intent.getStringExtra(EXTRA_PAYLOAD));
6666
} else if (ACTION_SQAN_BROADCAST.equalsIgnoreCase(action)) { //forward traffic from SqAN
6767
String origin = intent.getStringExtra(EXTRA_ORIGIN);
68-
if (!BuildConfig.APPLICATION_ID.equalsIgnoreCase(origin)) {
68+
if (!context.getPackageName().equalsIgnoreCase(origin)) {
6969
String channel = intent.getStringExtra(SQAN_PACKET_CHANNEL);
7070
if ((SosIpcTransceiver.channel != null) && SosIpcTransceiver.channel.equalsIgnoreCase(channel)) { //only handle SOS-T channel broadcasts
7171
try {

0 commit comments

Comments
 (0)