mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-16 12:47:32 +01:00
Amazfit Bip S: Fix crash with notifictions with only a title (GitNex does this)
Probably affects other newer Huami devices
This commit is contained in:
parent
c7f75c3dc3
commit
d0c5ffec28
@ -645,6 +645,9 @@ public class HuamiSupport extends AbstractBTLEDeviceSupport {
|
||||
if (notificationSpec.body != null) {
|
||||
message += StringUtils.truncate(notificationSpec.body, 512);
|
||||
}
|
||||
if (notificationSpec.body == null && notificationSpec.subject == null) {
|
||||
message += " "; // if we have no body we have to send at least something on some devices, else they reboot (Bip S)
|
||||
}
|
||||
|
||||
try {
|
||||
TransactionBuilder builder = performInitialized("new notification");
|
||||
|
Loading…
x
Reference in New Issue
Block a user