mirror of
https://github.com/dpup/meshstream.git
synced 2026-05-02 11:32:25 +02:00
Better error cards for private messages, neighbor info rendering
This commit is contained in:
@@ -308,7 +308,12 @@ func decodeEncryptedPayload(data *meshtreampb.Data, encrypted []byte, channelId
|
||||
TextMessage: string(decrypted),
|
||||
}
|
||||
} else {
|
||||
data.DecodeError = fmt.Sprintf("failed to parse decrypted data: %v", err)
|
||||
// Check if this channel is configured - if not, likely a private message
|
||||
if !IsChannelConfigured(channelId) {
|
||||
data.DecodeError = fmt.Sprintf("PRIVATE_CHANNEL: failed to parse decrypted data on unconfigured channel '%s': %v", channelId, err)
|
||||
} else {
|
||||
data.DecodeError = fmt.Sprintf("PARSE_ERROR: failed to parse decrypted data: %v", err)
|
||||
}
|
||||
data.Payload = &meshtreampb.Data_BinaryData{
|
||||
BinaryData: decrypted,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user