mirror of
https://github.com/dz0ny/meshcore-sar.git
synced 2026-08-11 16:30:28 +00:00
Remove sender name from notification
This commit is contained in:
@@ -765,14 +765,14 @@ class MessagesProvider with ChangeNotifier {
|
||||
final seconds = (voiceEnvelope.durationMs / 1000).ceil();
|
||||
final summary =
|
||||
'Voice message - ${voiceEnvelope.mode.label} - ${seconds}s - ${voiceEnvelope.total} packets';
|
||||
return isChannelMessage ? '$senderName\n$summary' : summary;
|
||||
return summary;
|
||||
}
|
||||
|
||||
final imageEnvelope = ImageEnvelope.tryParse(message.text);
|
||||
if (imageEnvelope != null) {
|
||||
final summary =
|
||||
'Image - ${imageEnvelope.format.label} - ${imageEnvelope.width}x${imageEnvelope.height} - ${_formatBytes(imageEnvelope.sizeBytes)}';
|
||||
return isChannelMessage ? '$senderName\n$summary' : summary;
|
||||
return summary;
|
||||
}
|
||||
|
||||
if (!isChannelMessage && message.recipientPublicKey != null) {
|
||||
@@ -785,10 +785,6 @@ class MessagesProvider with ChangeNotifier {
|
||||
}
|
||||
}
|
||||
|
||||
if (isChannelMessage) {
|
||||
return '$senderName\n${message.text}';
|
||||
}
|
||||
|
||||
return message.text;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user